Closed (won't fix)
Project:
Superfish Dropdown Menu
Version:
7.x-1.x-dev
Component:
Code
Priority:
Major
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
4 Apr 2013 at 13:23 UTC
Updated:
21 Jul 2013 at 15:14 UTC
Jump to comment: Most recent file
Comments
Comment #1
discipolo commentedinitial stab at this, would probably need a config option as well as preserve alphanumerics and remove colons
Comment #2
mehrpadin commentedHey everybody,
Apologies for missing this; I don't think it's a good idea, because titles are usually too long for this, and often not so static like the IDs are, let alone the i18n and so on; but you can easily add them, for example: http://kahthong.com/2011/12/themer-friendly-menu-link-css-classes-drupal...
Comment #3
discipolo commentedi tried that, following https://drupal.org/node/345624 but it was tricky, http://drupal.stackexchange.com/questions/16153/alter-menu-structure-whe.... Also menu titles dont tend to be that long in my experience, translation point taken though.
Comment #4
mehrpadin commentedNo longer, we now have these two:
theme_superfish_menu_item&theme_superfish_menu_item_linkthat you can easily override; also those wishing better performance can easily disable these via block configuration (under More Options) and so on, yes haven't updated the documentation yet!Comment #5
discipolo commenteddoes that mean that it should also be possible to add the class via a preprocess function since it looks like theme_superfish_menu_item line 15 adds the classes to the li element using drupal_attributes($element['attributes'])? What would be the right way to extend the classes there?
none of those two seem to be using theme_menu_link...
Comment #6
mehrpadin commentedYes, just mix my example above with the theme hook and you'll get:
Comment #7
discipolo commentedawesome, i had to change it to use link_title instead of just title, probably due to my theme ...
Comment #8
mehrpadin commented:)