[drupal-devel] [feature] Flat out $node in phptemplate_node vars

chx drupal-devel at drupal.org
Sun Jul 17 19:50:04 UTC 2005


Issue status update for 
http://drupal.org/node/24862
Post a follow up: 
http://drupal.org/project/comments/add/24862

 Project:      Drupal
 Version:      cvs
 Component:    theme system
 Category:     feature requests
 Priority:     normal
 Assigned to:  chx
 Reported by:  chx
 Updated by:   chx
 Status:       patch
 Attachment:   http://drupal.org/files/issues/nodevarsflat_1.patch (1.43 KB)

Dries is also right that some code can be removed.




chx



Previous comments:
------------------------------------------------------------------------

1118600180 : chx

Attachment: http://drupal.org/files/issues/nodevarsflat.patch (907 bytes)

I'd like to write $whatever in node.tpl.php instead of $node->whatever .
Hence the patch.




------------------------------------------------------------------------

1118600596 : adrian

i am gonna +1 this, as it simplifies the available variables.




------------------------------------------------------------------------

1118848671 : Bèr Kessels

I Add my +1 to the 'heap' too. But a slight additional feature:
Maybe we should then omit teh $node completely. It makes not much sense
IMO to use the overheard of parsing along a rather often-used, and big
varible, when its availabe in another form already
Maybe you should do some checking for already existing variables. One
nevver really knows w




------------------------------------------------------------------------

1118945315 : Morbus Iff

+1 to the flat, -1 to removing $node. I use various functions within my
templates that require a $node object to be passed to them.




------------------------------------------------------------------------

1121592652 : chx

Attachment: http://drupal.org/files/issues/nodevarsflat_0.patch (829 bytes)

Morbus is right.







More information about the drupal-devel mailing list