I’ve been doing research about this but I’m stuck and I can’t figure out a clean solution. Right now I have a menu with items that link to categories. This menu has LI elements, and for example, the elements have classes such as menu-item-XX, being XX an ID that is assigned to them by WordPress. I would like to generate this menu in order for the LI’s also to have a class such as ‘category-XX’ being the XX the category ID of such category. I think I can do it with a custom Walker, but I don’t know exactly how. Any ideas?
Thanks so much,
The topic ‘How to generate menu of categories with li class category ID’ is closed to new replies.