WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am creating a theme from scratch and the navigation menu is disturbing me because it is displaying the permalinks after the menu item name. See this picture


Link name (#permalink) is the result of wp_nav_menu()

Setting e.g. $before/$after - yields text before/after (#permalink)

The (#permalink) part is not displayed in the source.

Since it's only Pages I tried wp_list_pages(), but that gives me the same result.

Any ideas on how to remove those permalinks? I believe there is some 'default' setting for how links/menu items should be displayed but I don't know where to look.


share|improve this question
up vote 0 down vote accepted

Since the (#url) isn't displayed in the source, I suspect this is being placed there by CSS with a rule like:

#menu a:after { content: "#"attr(href); }

If I had to guess it's a print stylesheet run amok, possibly from a plugin.

share|improve this answer
Yes you're right. As a matter of fact, all links have that "bug". How come? – Hajder Rabiee May 16 '12 at 19:25
It's a theming or plugin issue. Use a tool like Firebug to track down which style sheet it's in and then work backwards from there. Like I said, it's a common thing in Print stylesheets, so if you have a plugin that does that, I'm guessing it's the culprit. – mrwweb May 16 '12 at 20:38
If you send me a link, I can track it down very quickly. – mrwweb May 16 '12 at 20:45
I think it's blueprint CSS framework. Thanks! – Hajder Rabiee May 17 '12 at 7:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.