Forked from westonruter/nav-menu-item-custom-fields.php
Created
September 29, 2012 15:39
-
-
Save kucrut/3804376 to your computer and use it in GitHub Desktop.
Proof of concept for how to add new fields to nav_menu_item posts in the WordPress menu editor.
if anyone gets to here, this is now packaged into a library that you can use
How to do when there's two or more fields 'item_tpl', 'item_tpl2', 'item_tpl3'
I got an error when I do this code below.
$new_fields .= str_replace(
array_map(function($key){ return '{' . $key . '}'; }, array_keys($field)),
array_values(array_map('esc_attr', $field)),
self::$options['item_tpl', 'item_tpl2', 'item_tpl3']
);
Please help Thanks!
Hi friends,how to add checkbox and/or select input ?
and how to get values ??
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If anyone here - how to add checkbox and/or select input ?