- This topic has 8 replies, 5 voices, and was last updated 2 years, 6 months ago by
Movin.
- AuthorPosts
- June 13, 2014 at 10:39 am #7854
Steve87
MemberHi,
when holding the mouse on a menu item a description of the link appears (html title attribute).
For menu item “Item 1” I don’t need a description “Item 1” displayed because it is obvious.Is there a way to hide this description? Maybe via Custom CSS? I have not set up “HTML-Attribut title (optional)” in the Menu Editor.
Thanks!
SteveJune 13, 2014 at 1:42 pm #7858Aigars
KeymasterTitle is enabled to provide custom functionality for menu such as icons, dividers, sections, deactivated items etc. You can go ahead and edit default nav walker which you can find in theme folder – inc – navwalker.php
June 16, 2014 at 7:43 am #7950Steve87
MemberThanks Aigars, it does work!
If anyone else is interested in the solution:
Comment the following line out:
$atts['title'] = ! empty( $item->title ) ? $item->title : '';
=>
// $atts['title'] = ! empty( $item->title ) ? $item->title : '';
I do not know if there are other parts that will not work or if it has negative influence on searchmachines, but icons do work as well as the divider!
Kind regards!
SteveJune 16, 2014 at 9:23 am #7959Aigars
KeymasterThank you for posting this solution here! I hope others will find it useful as well.
Thank you!
June 3, 2015 at 5:30 pm #23359redspiralhand
ParticipantHow could I change the code so that the custom attribute/description that I add to the menu items shows up instead of the title?
right now it’s just the title showing on rollover.
Thank you!
- This reply was modified 4 years, 6 months ago by
redspiralhand.
June 4, 2015 at 6:10 pm #23442Aigars
KeymasterThis theme uses “Title Attribute” to add icons inside menu like it is described on theme documentation.
It doesn’t have default WordPress menu behavior because of those icons as we have to find some field to use for them.
June 4, 2015 at 6:16 pm #23445redspiralhand
ParticipantThank you for your response…
Is there any way to create an item that pops up on roll over of the 2nd level menu item for some brief line of text to be shown?
thank you!
Dawn
May 25, 2017 at 12:11 pm #100988spas
ParticipantHello,
I’ve accomplished this task via custom function (added in functions.php) and javascript. Unfortunately, because of this site’s security policy, I can’t upload or paste the code here.
Sources:
Best regards and thank you very much for this nice WP theme!
Spas- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
- This reply was modified 2 years, 6 months ago by
spas.
May 26, 2017 at 11:06 am #101137 - This reply was modified 4 years, 6 months ago by
- AuthorPosts
- The topic ‘Remove title attribute from main menu links for Sparkling theme’ is closed to new replies.