Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

For some reason, my menu items are showing tooltips on hover-over- In other words, the menu links have "title" attributes being added to them. Looking at my other, older WordPress sites, this is not the case. I can't remember having this issue before- Why would this be happening?

Thanks-

share|improve this question
add comment

2 Answers 2

up vote 1 down vote accepted

Here’s the code to remove it from wp_page_menu(), wp_nav_menu() and wp_list_categories() function:

function my_menu_notitle( $menu ){
  return $menu = preg_replace('/ title=\"(.*?)\"/', '', $menu );

}
add_filter( 'wp_nav_menu', 'my_menu_notitle' );
add_filter( 'wp_page_menu', 'my_menu_notitle' );
add_filter( 'wp_list_categories', 'my_menu_notitle' );

Source

share|improve this answer
add comment

I fixed this by adding a explicitly creating a menu vs relying on the default. Don't know why this would help (Figured it was an argument in wp_nav_menu_args but I couldn't find any dealing with this.)

share|improve this answer
add comment

Your Answer

 
discard

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.