I read what reported in How do I change html structure of menu (primary links for example) to my own? but the accepted answer for that question is for Drupal 6.

How do I create a function that adds a CSS class or ID to a single "li" and "sub li"?


It's useful to refer to the API documentation when you have an idea of what to do in version 'X' of Drupal and you want to translate the method to work in version 'Y'.

In this instance, the following API page will prove useful:


| improve this answer | |

I found the solution here to change the primary menu links in Drupal 7


| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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