what is the best way to make a wordpress menu that has a list seperator? The seperator would need to be generated dynamically. So how is this done?
- Sold between 250 000 and 1 000 000 dollars
- Community Moderator
- Author was Featured
- Item was Featured
- Bought between 50 and 99 items
- Referred between 1000 and 1999 users
- Has been a member for 3-4 years
- Repeatedly Helped protect Envato Marketplaces against copyright violations
What do you mean by it needs to be done dynamically? Are you saying that a simple CSS solution wouldn’t work?
To make the CSS solution more dynamic, you can use the “CSS Classes” option in the Menu Manager. Click Screen Options and check the “CSS Classes” checkbox to activate this. Then you can apply a special class that would create a divider. That’s your easiest “dynamic” solution.
For a more advanced solution, I just finished writing a plugin that should be released soon to do with the WP3 Menu Management system (see my profile if you’re interested, I don’t want to self-promote here). One simplistic way to do this is to use a special tag/character sequence as a divider (like
--divide--) and then write a custom menu walker to handle it. Kriesi’s tutorial can give you the insight you need to write the walker: http://www.kriesi.at/archives/improve-your-wordpress-navigation-menu-output
Hope that helps