Skip to content

Instantly share code, notes, and snippets.

View ss2010's full-sized avatar

Sunil Sharma ss2010

View GitHub Profile
@ss2010
ss2010 / readme.md
Created May 1, 2019 14:14 — forked from hitautodestruct/readme.md
Generate a custom structure for Wordpress menus.

This gist is for showing an example of a custom wordpress menu.

If you want to get more from the menu item simply have a look at the $item object. i.e:

// Will return a large object with lots of props like title, url, description, id etc.
var_dump( $item );

This code works on Wordpress 4.1.1 as of 31st of March 2015