Steven Wittens
569ede574f
#115139 : Add centralized json handler (and send text/javascript content-type header).
2007-06-22 08:46:16 +00:00
Steven Wittens
fe8b35f527
#153781 : Convert all remaining confirm_forms() to deletion api.
2007-06-22 08:32:28 +00:00
Steven Wittens
38a1300df2
#147723 : Deletion API (by hunmonk). Woop woop.
2007-06-22 05:44:21 +00:00
Dries Buytaert
ba32a804a9
- Patch #150299 by asimmonds: form API fixes in taxonomy.module.
2007-06-17 10:47:12 +00:00
Dries Buytaert
29eb5a6284
- Patch #146910 by dww: only allow enabling modules with the same Drupal core compatibility version.
2007-06-08 05:50:58 +00:00
Dries Buytaert
27388f6655
- Patch #149176 by chx, David et al: getting rid of the sequences table, using db_last_insert_id() instead of db_next_id().
2007-06-05 12:13:23 +00:00
Dries Buytaert
e629deb94d
- Patch #146667 by Jeff Eaton: form API fixes.
2007-06-04 15:56:34 +00:00
Dries Buytaert
1fe90cba4f
- Patch #146667 by Eaton: correct builder argument ordering, eliminate redundant arguments
2007-06-04 07:22:23 +00:00
Dries Buytaert
96926ca047
- Patch #146470 by Eaton et al: standardize form API3 hook parameter order.
2007-05-28 06:08:47 +00:00
Dries Buytaert
3cafffe63f
- Killer patch #144765 by bjaspan, frando et al: schema API 1 hits core. Oh, behave.
2007-05-25 12:46:46 +00:00
Dries Buytaert
ac65ff9074
- Patch #138706 by eaton, chx, webchick, yched et al: form api 3 ... yay. :)
2007-05-14 13:43:38 +00:00
Dries Buytaert
304400293a
- Patch #141204 by Wim Leers: fixing caching bug in taxonomy_node_get_terms().
2007-05-04 08:38:34 +00:00
Dries Buytaert
7d4f2836ba
- Patch #128082 by Goba et al: Allow localization of built-in menu items.
2007-04-30 17:03:29 +00:00
Gábor Hojtsy
359ace36e6
#76588 patch by alienbrain: some localization-unfriendly watchdog() calls
2007-04-24 18:23:48 +00:00
Dries Buytaert
e98c82e679
- Patch #136202 by asimmonds: fixed indefined variable notice.
2007-04-15 15:59:06 +00:00
Dries Buytaert
e675979091
- Patch #134493 by douggreen: getting the Drupal coding standards right in core. Woot. Woot.
2007-04-13 08:56:59 +00:00
Steven Wittens
2a10f18211
- Fix bad code in taxonomy.module (variable naming)
2007-04-11 09:17:53 +00:00
Dries Buytaert
8e990d6935
- Patch #35177 by Stefan and profix898: added some logging to the taxonomy module.
2007-04-10 11:28:18 +00:00
Dries Buytaert
30bf1d53ae
- Patch #100429 by Zen, RobRoy and kkaefer: remove the content type requirement.
2007-04-10 10:16:29 +00:00
Dries Buytaert
5bbbf10ba8
- Patch #130987 by merlinofchaos: added theme registry for easier themability.
2007-04-06 13:27:23 +00:00
Steven Wittens
c504141f45
#133858 : Code cleanup and e_notices in taxonomy.module for tag parsing.
2007-04-05 03:08:48 +00:00
Steven Wittens
f7440d4d73
#130971 : Kitchen sink (E_NOTICE compliance / Code style / Bugfix in book toc)
2007-03-27 05:13:55 +00:00
Dries Buytaert
eb6b848de6
- Patch #110888 by Eaton: unify hook _alter()
2007-03-26 00:35:59 +00:00
Dries Buytaert
f37abe6074
- Patch #130831 by ChrisKennedy: l() error in taxonomy.module.
2007-03-25 19:06:53 +00:00
Dries Buytaert
e6543caaff
- Patch #112556 by Robroy: term/vocab maxlength should match db.
2007-02-27 12:48:33 +00:00
Dries Buytaert
dc5843bd30
- Patch #111347 by Steven: refactor url() and l().
2007-02-15 11:40:19 +00:00
Dries Buytaert
72501e54df
- Patch #115667 by rotzi: added versioning support to node terms.
2007-02-12 17:47:08 +00:00
Dries Buytaert
a1e6728a46
- Patch #113603 by chx: first crack at re-implementing tabs.
2007-02-11 09:30:51 +00:00
Dries Buytaert
489903a08e
- Patch #113603 by chx: first crack at re-implementing tabs.
2007-01-31 21:26:56 +00:00
Dries Buytaert
05a708fb06
- Patch #112715 by chx, webchick, asimmonds, et al: fixing E_ALL notices. Thanks.
2007-01-31 15:49:26 +00:00
Dries Buytaert
3b543c18f5
- Rollback of E_ALL patch. Too much extra breakage.
2007-01-25 22:14:06 +00:00
Dries Buytaert
db7dcfd444
- Patch #112556 by webchick: term/vocab maxlength should match db.
2007-01-25 21:51:20 +00:00
Dries Buytaert
fd32b42196
- Patch #112715 by webchick et al: fixed some E_ALL errors.
2007-01-25 21:32:07 +00:00
Dries Buytaert
03752e35a4
- Patch #34755 by chx et al: faster menu system. HEAD is temporary broken and there is no upgrade path yet.
2007-01-24 14:48:36 +00:00
Dries Buytaert
cd9ceae7a1
- Patch #107426 by webchick: code cleanup.
2007-01-23 19:04:21 +00:00
Steven Wittens
c4c9d2a5d5
#108363 : Faster tag parsing (preg_match to strpos).
2007-01-11 03:29:15 +00:00
Dries Buytaert
a746d0496a
- Patch #103462 by jvandyck: documentation and grammar clean up.
2006-12-20 10:32:16 +00:00
Steven Wittens
a0b5a225d3
Removing useless taxonomy.css
2006-11-30 07:05:57 +00:00
Dries Buytaert
7ddfac434a
- Patch #99694 by bdragon: removed dead code.
2006-11-28 13:15:31 +00:00
Neil Drumm
b8127a29c5
#97995 by chx. Only make menu items when the path is correct.
2006-11-26 23:53:20 +00:00
Neil Drumm
b5bf8a8f47
#97824 by Gurpartap. Move enclosing elements outside of their t().
2006-11-26 02:20:01 +00:00
Dries Buytaert
6ae6dc0d85
- Patch #87298 by webchick, neil, dww et al: show version numbers on modules page.
2006-11-21 20:55:36 +00:00
Dries Buytaert
b004f328ee
- Patch #92992 by webchick and neclimdul: clean up documentation that is superseded by the new 'by module' administration dashboard.
2006-11-21 20:14:19 +00:00
Neil Drumm
4476a2c015
#83202 by Jaza. Separate out node type deletion API and use it to keep {vocabulary_node_types} updated.
2006-11-10 19:40:23 +00:00
Neil Drumm
4573af1f55
#80257 by Jaza. Add a hook for content type changes and use it for keeping vocabulary associations.
2006-10-31 17:01:04 +00:00
Steven Wittens
36d44fbfb0
#84146 : Use 'Sentence capitalization' for menu items, page titles, form items, etc
2006-10-22 08:28:47 +00:00
Neil Drumm
2ac86c8862
#24023 by chx. Allow multiple select options with the same value and implement it for taxonomy selection.
2006-10-20 20:55:03 +00:00
Dries Buytaert
d9ed1a9f66
- Patch #87185 by robert: added caching to taxonomy_get_term().
2006-10-18 11:15:51 +00:00
Dries Buytaert
370de93087
- Patch #89044 by beginner: cannot edit parent term.
2006-10-13 14:59:03 +00:00
Dries Buytaert
18b297abf8
- Patch #81740 by merlinofchaos, webchick, moshe, neclimdul et al: added package support to the modules page.
2006-10-05 15:47:57 +00:00
Neil Drumm
931f43f2ba
#41484 by myself. Fix singleton term selection.
2006-09-21 15:31:24 +00:00
Neil Drumm
1081f92732
#41484 by nickl, flk, and budda. Don't wrap the category selection in a fieldset if there is only one vocabulary.
2006-09-11 08:18:24 +00:00
Neil Drumm
6d3ab3e030
#74976 by RobRoy and mrgeneyuss. Clone category objects for multi-parent heirarchy.
2006-09-08 23:34:32 +00:00
Neil Drumm
0ae3912031
#31874 by David Lesieur. Call taxonomy hook for insert and update after the term is fully saved.
2006-09-08 20:18:35 +00:00
Neil Drumm
4fb76f680f
#67647 by fgm and nickl. Don't make a taxonomy option for vocabularies without terms.
2006-09-06 07:22:41 +00:00
Dries Buytaert
49fa25fb76
- Rollback of patch #68418 : clean up node submit hooks. Needs more thinkering.
...
Restores the old node API.
2006-08-31 21:58:36 +00:00
Dries Buytaert
c64db1da29
- Patch #80952 by earl, webchick, neclimdul et al: .info files
2006-08-31 20:22:37 +00:00
Dries Buytaert
5524604a95
- Patch #68418 by Moshe et al: clean up node submit hooks.
2006-08-29 18:43:26 +00:00
Neil Drumm
bceaf8f0da
#80574 Eaton and chx. Replace $_POST['edit'] with $_POST.
2006-08-29 09:12:03 +00:00
Dries Buytaert
a54ba6b1ed
- Patch #56093 by chx: use native php function where possible _taxonomy_depth() -> str_repeat()
2006-08-24 06:29:50 +00:00
Neil Drumm
153fbc7839
#79732 by drewish, fix the taxonomy forms and some code cleanup.
2006-08-24 05:43:38 +00:00
Dries Buytaert
2d05938082
- Patch #66569 by m3avrck: Consolidate the drupal_add_link() calls.
2006-08-23 07:23:09 +00:00
Neil Drumm
a58d877108
#66569 by m3avrck. Put all the feed icons in the same place.
2006-08-23 05:55:38 +00:00
Steven Wittens
55eec8f66f
#79601 : module_exist() -> module_exists()
2006-08-20 05:57:41 +00:00
Dries Buytaert
7de41539df
- Patch #77919 by chx, eaton, moshe, et al: enable programmaticaly submitted forms via the pull model.
2006-08-18 18:58:47 +00:00
Steven Wittens
81938a3cdc
#76802 : Introduce placeholder magic into t()
...
See: http://drupal.org/node/64279#t-placeholders
2006-08-18 12:17:00 +00:00
Neil Drumm
d58a0aa533
#77402 by Zacker, fix the node type checkboxes on vocabulary editing.
2006-08-15 05:50:48 +00:00
Neil Drumm
3cc2b1e3d7
#77183 by m3avrck and timcn, split up drupal.css by module.
2006-08-14 07:14:50 +00:00
Dries Buytaert
91942614d6
- Patch #62362 by Moshe: kill the 'form' operation of hook_taxonomy.
2006-08-08 18:55:53 +00:00
Dries Buytaert
729fa6c11b
- Patch #77422 by timcn: corrected various paths in the documentation.
2006-08-07 15:04:16 +00:00
Neil Drumm
129c8eb18c
#62340 by chx, webchick, Jaza, Eaton, mathieu, and myself. Configurable node types.
2006-08-06 23:00:42 +00:00
Dries Buytaert
eaf3540175
- Patch #76702 by timcn: fixed some broken admin pages.
2006-08-02 13:44:07 +00:00
Dries Buytaert
b138793b68
- Patch #72079 by Earl et al: give Drupal an overall administration page ... :-)
2006-07-31 11:25:55 +00:00
Neil Drumm
3cd232e5d4
#33772 by dfg, add title to last breadcrumb element.
2006-07-14 01:01:15 +00:00
Dries Buytaert
89c68399bc
- Patch #73361 by Ber: remove unneeded size restriction for vocabulary help.
2006-07-13 11:53:33 +00:00
Dries Buytaert
e93f8be871
- Patch #72204 by nedjo: upper-cased all TRUE/FALSE/NULL constants.
2006-07-05 11:45:51 +00:00
Neil Drumm
59aa2ae8e8
#71925 by Steven, remove # prefix from link array keys.
2006-07-04 08:59:05 +00:00
Neil Drumm
685be2ffce
#71728 by Eaton, re-add taxonomy_term_path()
2006-07-02 01:13:45 +00:00
Neil Drumm
930f8ca445
#61912 by doq and killes, add db_rewrite_sql() to taxonomy/autocomplete.
2006-06-11 22:46:20 +00:00
Dries Buytaert
23f643507f
- Improved input checking.
2006-06-01 18:40:24 +00:00
Dries Buytaert
9b8733bca6
- Patch #65324 by greggles: bungie -> bungee
2006-05-26 21:34:12 +00:00
Dries Buytaert
02fa0d85b2
- Patch #18018 by dww, nedjo, tostinne, luke et al: block visibility by role.
2006-05-26 09:21:10 +00:00
Neil Drumm
d80a410bb0
#64951 by deepstar, Ambiguous query in taxonomy_get_term_by_name()
2006-05-24 04:54:52 +00:00
Neil Drumm
70b7809121
#41042 by DriesK, Moshe, and Jaza, Duplicate tag handling
2006-05-23 02:21:26 +00:00
Neil Drumm
a5263bd284
#62926 by Richard Eriksson, Increase maximum length of the free-tagging textbox to 255 characters.
2006-05-20 02:05:35 +00:00
Dries Buytaert
1b291a2917
- Patch #18260 by Ber, m3averck et al: allow overriding of links returned by modules
2006-05-18 14:58:57 +00:00
Neil Drumm
9d8799f6c4
Reverting #53653 , that function actually is called via a module_invoke() in node.module.
2006-05-16 06:50:21 +00:00
Neil Drumm
0652e5b5cc
#53653 by me, remove an unused function.
2006-05-16 02:22:58 +00:00
Dries Buytaert
5b3f42372f
- Patch #62554 by webchick: removed some cruft.
2006-05-09 14:16:49 +00:00
Dries Buytaert
823673a196
- Patch #62332 by Zen: added missing add term link on admin/taxonomy page and got rid of some crufty code.
2006-05-08 15:12:25 +00:00
Neil Drumm
926cf39cf5
#47042 by RobertDouglas, Expose terms string parsing as a helper function to cut down on copy and paste code in contrib modules
2006-05-07 03:33:03 +00:00
Neil Drumm
9cff02e91b
#61802 by Zen, Double spaced sentences clean up
2006-05-07 00:08:36 +00:00
Neil Drumm
d6b538eff8
Forward port from 4.7
...
#60934 , The vocabulary list screen needs an 'add term' operation, patch by chx
2006-04-30 00:39:11 +00:00
Gerhard Killesreiter
f16b6b2901
#60621 , typo orm_set_error("taxonomy[tags][$vid", patch by chx
2006-04-28 12:02:18 +00:00
Steven Wittens
954cbf7c65
#60729 : Index taxonomy terms with nodes
2006-04-27 22:20:51 +00:00
Gerhard Killesreiter
8dfca7c806
#60265 , module field for vocabularies reverts to taxonomy, patch by naquah
2006-04-25 11:51:51 +00:00
Gerhard Killesreiter
99e7c0ec7c
#48526 , fix taxonomy for blogapi. Patch by walkah
2006-04-11 17:57:37 +00:00
Steven Wittens
9794b5538e
- #55898 : Generic, permissive admin XSS/HTML filtering for mission/footer/...
...
- Clean up some raw output
2006-04-07 15:32:17 +00:00
Steven Wittens
be0b774cbc
- #57523 : Make taxonomy delete vocabulary consistent with other taxonomy hook ops
2006-04-06 04:21:12 +00:00
Steven Wittens
4821200689
#57415 : Replace drupal_implode_autocomplete() by drupal_to_js()
2006-04-06 02:41:48 +00:00
Gerhard Killesreiter
3c795c554f
#28625 , further form API conversion of taxonomy.module and small bugfix in forms API, patch by profix898 and chx
2006-03-26 16:59:17 +00:00
Gerhard Killesreiter
02ad2cfea2
#53351 , remove preselection of "none", patch by myself.
2006-03-24 14:49:45 +00:00
Gerhard Killesreiter
d11c07502d
#54910 , Forum and taxonomy term delete work only superficially, patch by Zen
2006-03-23 21:46:35 +00:00
Dries Buytaert
718b88e54f
- Patch #53351 by Zen, tim et al: problem with unchecked taxonomy lists.
2006-03-11 13:47:51 +00:00
Dries Buytaert
7add598ee2
- Patch #51850 by chx, webchick et al: fixed various problems with db_rewrite_sql, made db_rewrite_sql slightly more robust.
2006-03-08 15:13:20 +00:00
Dries Buytaert
403bc4ab49
- Patch #51871 by merlinofchaos/zen: convert taxonomy.module to new form API so forms can be themed/altered properly.
2006-03-02 08:27:59 +00:00
Dries Buytaert
10dc538cf1
- Patch #51531 by Zen: renamed a link for clarity.
2006-02-27 17:01:37 +00:00
Dries Buytaert
3603fe1bd8
- Patch #49912 : www.drupal.org -> drupal.org. (Today's critical bugfix #5.)
2006-02-21 18:46:54 +00:00
Dries Buytaert
c3a0311b04
- Patch #39672 by Morbus: fixed problem with help texts of taxonomy forms.
2006-02-20 16:48:46 +00:00
Dries Buytaert
a94b87aa3a
- Patch #46705 by killes: use += instead of array_merge().
2006-02-20 16:39:23 +00:00
Dries Buytaert
9004bed664
- Patch #47899 by Zen: fixed weight issues with freetagging vocabulary.
2006-02-09 08:28:28 +00:00
Dries Buytaert
15ff8c8e32
- Patch #46827 by wulff: fixed incorrect links.
2006-01-29 07:50:45 +00:00
Dries Buytaert
7946eca135
- Patch #35926 by asimmonds: make required vocabularies actually required.
2006-01-26 08:33:20 +00:00
Dries Buytaert
10d7f7731b
- Patch #45281 by chx: made categories with forum topics work again.
2006-01-19 17:55:54 +00:00
Dries Buytaert
4c1522e962
- Patch #45336 by Ber: bugfix: removed obsolete check_plain() check causing & problems.
2006-01-19 09:26:15 +00:00
Dries Buytaert
a50eb34bda
- Patch #44381 by gerhard: improved consistency of API. Always pass an array.
2006-01-17 09:23:38 +00:00
Dries Buytaert
67778c896e
- Patch #39672 by Ber: made the help text opion work for free tagging terms.
2006-01-10 19:56:19 +00:00
Dries Buytaert
92acb92699
- Patch #33747 by Ber and Moshe: bugfix + code improvement: clean up some of the taxonomy loading code.
2006-01-10 12:35:20 +00:00
Dries Buytaert
16e9b4d0c7
- Patch #42937 by chx: bugfix: added missing db_rewrite_sql() in taxonomy_node_get_terms.
2006-01-08 12:28:27 +00:00
Dries Buytaert
ea2d791095
- Patch 41169 by Chris: got rid of expensvie object 2 array casts.
2005-12-31 10:48:56 +00:00
Steven Wittens
79a193a2d2
- #42234 : Use standardized feed icon for RSS
2005-12-29 04:46:40 +00:00
Steven Wittens
b43fa0f9da
- #41744 : global urlencode() for menu paths
2005-12-22 22:58:12 +00:00
Dries Buytaert
bd4fe6ede9
- Patch #40813 : Taxonomy forms should be in a fieldset.
2005-12-16 06:23:46 +00:00
Dries Buytaert
922a46d281
- Patch #34920 by Morbus/webchick/tangent: fixed order of form fields.
2005-12-15 16:24:40 +00:00
Dries Buytaert
764f1177ef
- Patch #40631 by Chris Johnson: is_array() slower than isset() or empty().
2005-12-14 20:10:45 +00:00
Dries Buytaert
32d9af4916
- Patch #39598 by Gerhard: fixed problem with taxonomy terms not being selected.
2005-12-06 12:20:24 +00:00
Dries Buytaert
ada8f8976f
- Patch #35125 by zoo33: made the taxonomy.module work with PostgreSQL.
2005-12-05 13:15:42 +00:00
Dries Buytaert
28fdb3975e
- Patch #39778 by chx: obliterate nodeapi op form in favor of the forms API's way of doing things. Tested with help from webchick.
2005-12-05 09:11:33 +00:00
Dries Buytaert
236da7af05
- Patch #31151 : adding taxonomy terms has no feedback
2005-11-29 17:41:27 +00:00
Dries Buytaert
42518af257
- Bring back taxonomy_form_all().
2005-11-28 12:24:58 +00:00
Dries Buytaert
679649baaa
- Patch #39003 by Jaza: remove taxnomy_form_all().
2005-11-27 09:26:46 +00:00
Dries Buytaert
d9dc551612
- Patch #29151 by fgm: simplified SQL query in taxonomy_node_form().
2005-11-23 08:27:55 +00:00
Dries Buytaert
aeed4cd8e4
- Patch #35644 by webchick: forms API simplificiations.
2005-11-12 11:26:16 +00:00
Steven Wittens
c2fcb6d519
#30993 : Make taxonomy selector widget themable
2005-11-12 04:31:56 +00:00
Dries Buytaert
42e2eb0d2a
- Patch #35178 by Robert Douglas: add title attribute to taxonomy links - use term description as text.
2005-11-08 15:17:34 +00:00
Dries Buytaert
a8b218827a
- Patch #26139 by webchick / Kieran / documentation team: improved admin help of core modules! /
2005-11-01 10:17:34 +00:00
Steven Wittens
6777fdb193
- #26583 : Make forum taxonomy links redirect to forums rather than taxonomy pages.
2005-10-21 11:12:46 +00:00
Steven Wittens
468b9e8e5a
- Code style
2005-10-19 09:46:22 +00:00
Dries Buytaert
782d5c98c9
- Patch #33752 by leafish_paul / adrian: added missing apostrophes to the form API code.
2005-10-18 14:40:00 +00:00
Dries Buytaert
75fe6b6c0a
- Patch #33752 by chx, adrian, et al: another batch of form API changes/fixes.
2005-10-11 19:44:35 +00:00
Dries Buytaert
7863be5e82
- Patch #33433 by chx: fixed a number of form API problems.
...
* Default form value
* Leftover debug function in form.inc
* PHP5 issue with comment date (I got this patch from another issue)
* Validation error fix (was calling legacy form validate)
* Lots o' warnings on comment preview
* Filter tips plus argument (gremlins. I swear this was not there.)
* Message to clear what's going on with system settings
* Non-freetagging taxonomies fixed
2005-10-08 12:21:47 +00:00
Dries Buytaert
a1ae4da70b
- Removing tabs and trailing whitespaces.
2005-10-07 06:51:43 +00:00
Dries Buytaert
7e1527ee61
- Patch #29465 : new form API by Adrian et al.
...
TODO:
+ The contact.module was broken; a new patch for contact.module is needed.
+ Documentation is needed.
+ The most important modules need to be updated ASAP.
2005-10-07 06:11:12 +00:00
Dries Buytaert
da316273bd
- Patch #31014 by chx, zack: on taxonomy overview pages, make term names link to their respective taxonomy/term/(x) page.
2005-09-19 15:04:11 +00:00
Dries Buytaert
1dc53d9761
- Patch #3986 by James (and Boris :)):consolidated all feed-related settings in one place.
...
* adds a "feed settings" section to admin/settings where 2 new settings are introduced:
* number of items per feed
* default length of feed descriptions (title only, teaser, full)
* patches all of core to obey the above - including the new aggregator (out) feeds
* adds support for adding namespaces in _nodeapi('rss item') - which means things like iTunes RSS and yahoo's media rss can be implemented by the appropriate modules (i.e. audio.module)
* includes some additional info in the default node feed - specifically the element (links directly to comments) - and dc:creator - to show node author information.
2005-09-18 10:37:57 +00:00
Dries Buytaert
074cafa269
- Patch #30956 by Cvbge: PostgreSQL fix: taxonomy_save_vocabulary() should check for 'tags' not set.
2005-09-12 21:55:41 +00:00
Dries Buytaert
8f71d8990e
- Patch #16452 by chx: allow modules to rewrite taxonomy-related SQL queries much
...
like we do with node-related SQL queries.
(chx promised to document this, check his documentation as soon it is available.)
2005-08-28 16:30:50 +00:00
Dries Buytaert
8f32c39db2
- Patch #29102 by chx: fixed bug in forum module and tidied up the taxonomy_save_*() functions.
2005-08-28 15:58:52 +00:00
Dries Buytaert
c9fc300b1f
- Patch #29785 by Chx: multiple node types were broken so we refactored
...
part of the node system! If you have a module that implements node
types, you'll have to udpate its CVS HEAD version.
We replaced _node_name() and _node_types() by _node(). The new _node()
hook let's you define one or more node types, including their names.
The implementation of the _node() hook needs to:
return array($type1 => array('name' => $name1, 'base' => $base1),
$type2 => array('name' => $name2, 'base' => $base2));
where $type is the node type, $name is the human readable name of the type
and $base is used instead of <hook> for <hook>_load, <hook>_view, etc.
For example, the story module's node hook looks like this:
function story_node() {
return array('story' => array('name' => t('story'), 'base' => 'story'));
}
The page module's node hook module like:
function page_node() {
return array('page' => array('name' => t('page'), 'base' => 'page'));
}
However, more complex node modules like the project module and the
flexinode module can use the 'base' parameter to specify a different base.
The project module implements two node types, proejcts and issues, so it
can do:
function project_node() {
return array(
array('project_project' => array('name' => t('project'), 'base' => 'project'),
array('project_issue' => array('name' => t('issue'), 'base' => 'project_issue'));
}
In the flexinode module's case there can only one base ...
This hook will simplify the CCK, and will make it easy (or easier) to merge
the story and page module.
In addition, node_list() became node_get_types(). In addition, we created
the following functions: node_get_name($type) and node_get_base($type).
2005-08-28 15:29:34 +00:00
Dries Buytaert
7b8a409675
- Patch #29385 by chx: no ?> add end of files.
2005-08-25 21:14:17 +00:00