Hi there,

I have a navigation menu built using the menu block in the drupal admin.

One of my menu items is "Update my details" which is currently pointing to a static node.

I would like this to link instead to the user/edit page so people can update their username, email and other profile bits.

The problem is, the url is /user/uid/edit, where uid is the, well, user id (so my edit page is /user/1/edit/)

How do i use the admin page and the text field for path to dynamically link to the edit page for the person currently logged in?

Thanks

Lee

Comments

junedkazi’s picture

JUNED KAZI
junedkazi@gmail.com

Hi,
I am a newbie.But I think u can solve this issue using theme_menu_item
http://api.drupal.org/api/function/theme_menu_item/5
just try it out and post a feedback.

Cheers

leemarrett’s picture

thanks juned -- i will keep this in mind but at this stage i'm trying to do what i need from the admin and without dipping into the code, as the bulk of the menu items are standard nodes and all configured through the admin.

rastarr’s picture

Couldn't you enable the Token module and use /user/[uid]/edit though ?

leemarrett’s picture

have tried enabling the token module -- the menu module doesn't seem to be supported as when i try and put /user/[uid]/edit into the "path" field for the menu item, drupal hides the menu item altogether :)

i'm looking into using the pathauto module however and hopefully this will help me do what i want...

rastarr’s picture

My apologies - I shouldn't have opened my gob without testing it first. Just presumed it should - no idea why it doesn't though.
Weird.
Again, sorry for that

WorldFallz’s picture

I did exactly this using the very small and simple 'me' alias module.

leemarrett’s picture

this did exactly what i needed as well :)

anyone looking to do this very thing should definitely check out the "me" module. works a treat, thanks worldfallz!

WorldFallz’s picture

glad I could help! now where's my round trip ticket to NZ.... lol...

leemarrett’s picture

haha it's in the post...