Hi

I have a normal menu inside a block on my front page. This menu contains one menu item.
I want a token in this menu item that gives the number of all nodes of a specific content type the current user made.

How can I do this? I found [node:content-type:node-count] but how can I tell the computer which content type i mean? Once again: I don't want the user to see the number of all nodes of a content type, but ONLY the number of his own nodes of this content type.

Thanks very much for your help.

Regards, Nico

Comments

Dave Reid’s picture

Status: Active » Fixed

You can't really use tokens in this way. You'd have to provide token_replace() with a node object in order to replace the token with the correct number, which is something you can't really do with menu links. Your best bet is to alter the menu links with a custom module yourself, possibly using hook_translated_menu_link_alter().

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.