[development] MENU_LOCAL_TASK for just some node types

Michael Favia michael at favias.org
Thu Jun 5 14:50:53 UTC 2008


Lluís wrote:
> My problem is there is no $node object to check $node->type. My menu
> definition is:

My mistake. You are correct. To my knowledge you will either have to 
load the node or if you have pathauto working and uniquely prefix the 
node type you can test the path for the presence of the token for that 
type. (it is pretty hackish but ive used it before to avoid the 
excessive database hits).


-- 
Michael Favia                   michael at favias.org
tel. 512.585.5650            http://www.favias.org


More information about the development mailing list