I wanted it for some time now, to be able to add a meta fields to menu items in the WordPress all-too-beautiful menu editing interface.
Haven’t had much luck finding a solution on the Interwebz. So I made my own. And then I found something quite similar to what I’ve done:
Main difference: my plugin uses phpQuery to “inject” additional html, and will therefore be hopefuly much more “updateable” in the future.
Here is a “skeleton” plugin that just adds a field to menu item and stores it as a meta value.
The plugins doesn’t do anything with it. For that, see some of the many tutorials online regarding the “menu walkers”.
This is intended for developers who need to be able to write a piece of information to the menu item and do something with it later on.
- explain plugin a bit