The standard Moshe is talking about is somewhat implied here at the bottom in the naming convention section: http://drupal.org/coding-standards It should probably be explicitly spelled-out though in terms of stuffing data into node objects and the like. I think putting it in doxygen is critical. I real api.drupal.org 100 times a day. Handbook maybe once a week. :) I (heart) standards. -josh
On May 29, 2007, at 6:23 PM, Moshe Weitzman wrote:
thata the drupal convention, and IMO it works quite well.
undocumented conventions that aren't expressed in the code of core are worthless, IMHO.
Contrib modules are second class citizens and should always prefix their variables, form fields, node elements, etc. this system works very well, when you use it.
so, you advocate "luck" as the solution to this problem. ;) fair enough. however, if core doesn't do this itself, we have to mention this in the developer docs, preferably in a few places like the doxygen for nodeapi('load'), the drupal coding convetions, etc, etc. if that's really the only answer here, i'll volunteer to submit the issue to the documentation queue...
thanks, -derek
p.s. project* was written by core maintainers, and has been doing this wrong for over 5+ years. if we can't trust the core maintainer's own contribs to provide best practices for this, who can we trust? ;) hence the need for docs and vastly more awareness of this problem by the rest of us 2nd class citizens.
Josh Koenig, Partner josh@chapterthreellc.com AIM: chap3josh 1-888-822-4273