Closed (fixed)
Project:
me aliases
Version:
6.x-2.4
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
10 Apr 2009 at 18:21 UTC
Updated:
23 Apr 2009 at 23:43 UTC
My theme goes through the "theme_menu_item_link" function to change the "My account" link title to the username. Is it still possible to do this with the "me" module enabled? It looks like it switches the theme function if it detects the "user/" path.
Comments
Comment #1
cdale commentedIt should work just fine. 'me' doesn't actually switch the theme function, it just intercepts it, makes a small change to the link item, then passes it on as though me never existed.
Are you experiencing trouble with this? Or did you just look at the code before using it? if you are having trouble, please report back here with as much information as you can. :)
Comment #2
mshaver commentedThanks for the reply. Here is the theme function I'm using that doesn't seem to work once "me" module is activated. This is a zen sub theme if that makes any difference? I moved the "My account" menu item out of the navigation and into a custom menu called "Persistent Links".
Comment #3
cdale commentedAhh, I see the problem. :) You need to name the function
custom_menu_item_linkwhere "custom" is your themes name. Be sure to clear the theme cache after making that change This is probably easiest done by visiting admin/build/themes.Does that work for you?
Comment #4
mshaver commentedSorry, I put "custom_theme" as a placeholder. The actual function does use the theme name like so: moblin2_menu_item_link($link).
Comment #5
cdale commentedhmmm... As far as I know, it should work. It's a zen sub theme you say? I might quickly make a zen sub theme and see what happens.
Comment #6
cdale commentedWell I just made a zen sub theme, and added the custom menu_item_link theme hook, and it gets called alright. Could it possibly be another module that is interfering? I'm assuming you already cleared all your caches. :)
I'd would think it might be another module though, as I have me installed with DHTML menu, which also overrides menu_item_link, and both modules and theme work fine. Me gets called first, which calls the DHTML menu one, which calls the theme layer.
I'm stumped, so any extra information you can provide might prove useful.
Comment #7
mshaver commentedStrange? The only module that invoked that function was the admin_menu module and it didn't fix the problem when I disabled it? I haven't upgraded to the latest Zen theme yet, but I doubt that function has changed in the newest? Maybe I should look into this though?
Thanks for your help and I'll keep digging around. :)
Comment #8
cdale commentedhmm... I also have admin_menu installed, so I don't think that's the problem. Does the problem still persist if you disable the 'me' module?
Comment #9
cdale commentedI don't think there is a problem with 'me' here so closing this issue. Please re-open if the problem still exists.
Comment #10
cdale commented