Skip to content

Instantly share code, notes, and snippets.

@javorszky
Created November 26, 2012 01:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save javorszky/4146115 to your computer and use it in GitHub Desktop.
Save javorszky/4146115 to your computer and use it in GitHub Desktop.
Adding extra classes to wp_nav_menu - part 3
Array
(
[0] => Array
(
[1] => WP_Post Object
(
[ID] => 100
[post_author] => 1
[post_date] => 2012-11-26 00:09:23
[post_date_gmt] => 2012-11-26 00:09:23
[post_content] =>
[post_title] =>
[post_excerpt] =>
[post_status] => publish
[comment_status] => closed
[ping_status] => open
[post_password] =>
[post_name] => 100
[to_ping] =>
[pinged] =>
[post_modified] => 2012-11-26 00:09:23
[post_modified_gmt] => 2012-11-26 00:09:23
[post_content_filtered] =>
[post_parent] => 0
[guid] => http://www.javorszky.co.uk/?p=100
[menu_order] => 1
[post_type] => nav_menu_item
[post_mime_type] =>
[comment_count] => 0
[filter] => raw
[db_id] => 100
[menu_item_parent] => 0
[object_id] => 95
[object] => page
[type] => post_type
[type_label] => Page
[url] => http://www.javorszky.co.uk/
[title] => Home
[target] =>
[attr_title] =>
[description] =>
[classes] => Array
(
[0] =>
[1] => menu-item
[2] => menu-item-type-post_type
[3] => menu-item-object-page
[4] => current-menu-item
[5] => page_item
[6] => page-item-95
[7] => current_page_item
)
[xfn] =>
[current] => 1
[current_item_ancestor] =>
[current_item_parent] =>
)
[2] => WP_Post Object
(
[ID] => 97
[post_author] => 1
[post_date] => 2012-11-26 00:09:23
[post_date_gmt] => 2012-11-26 00:09:23
[post_content] =>
[post_title] =>
[post_excerpt] =>
[post_status] => publish
[comment_status] => closed
[ping_status] => open
[post_password] =>
[post_name] => 97
[to_ping] =>
[pinged] =>
[post_modified] => 2012-11-26 00:09:23
[post_modified_gmt] => 2012-11-26 00:09:23
[post_content_filtered] =>
[post_parent] => 0
[guid] => http://www.javorszky.co.uk/?p=97
[menu_order] => 2
[post_type] => nav_menu_item
[post_mime_type] =>
[comment_count] => 0
[filter] => raw
[db_id] => 97
[menu_item_parent] => 0
[object_id] => 93
[object] => page
[type] => post_type
[type_label] => Page
[url] => http://www.javorszky.co.uk/wordpress-development/
[title] => WordPress Development
[target] =>
[attr_title] =>
[description] =>
[classes] => Array
(
[0] =>
[1] => menu-item
[2] => menu-item-type-post_type
[3] => menu-item-object-page
)
[xfn] =>
[current] =>
[current_item_ancestor] =>
[current_item_parent] =>
)
[3] => WP_Post Object
(
[ID] => 99
[post_author] => 1
[post_date] => 2012-11-26 00:09:23
[post_date_gmt] => 2012-11-26 00:09:23
[post_content] =>
[post_title] =>
[post_excerpt] =>
[post_status] => publish
[comment_status] => closed
[ping_status] => open
[post_password] =>
[post_name] => 99
[to_ping] =>
[pinged] =>
[post_modified] => 2012-11-26 00:09:23
[post_modified_gmt] => 2012-11-26 00:09:23
[post_content_filtered] =>
[post_parent] => 0
[guid] => http://www.javorszky.co.uk/?p=99
[menu_order] => 3
[post_type] => nav_menu_item
[post_mime_type] =>
[comment_count] => 0
[filter] => raw
[db_id] => 99
[menu_item_parent] => 0
[object_id] => 84
[object] => page
[type] => post_type
[type_label] => Page
[url] => http://www.javorszky.co.uk/about/
[title] => About
[target] =>
[attr_title] =>
[description] =>
[classes] => Array
(
[0] =>
[1] => menu-item
[2] => menu-item-type-post_type
[3] => menu-item-object-page
)
[xfn] =>
[current] =>
[current_item_ancestor] =>
[current_item_parent] =>
)
[4] => WP_Post Object
(
[ID] => 98
[post_author] => 1
[post_date] => 2012-11-26 00:09:23
[post_date_gmt] => 2012-11-26 00:09:23
[post_content] =>
[post_title] =>
[post_excerpt] =>
[post_status] => publish
[comment_status] => closed
[ping_status] => open
[post_password] =>
[post_name] => 98
[to_ping] =>
[pinged] =>
[post_modified] => 2012-11-26 00:09:23
[post_modified_gmt] => 2012-11-26 00:09:23
[post_content_filtered] =>
[post_parent] => 0
[guid] => http://www.javorszky.co.uk/?p=98
[menu_order] => 4
[post_type] => nav_menu_item
[post_mime_type] =>
[comment_count] => 0
[filter] => raw
[db_id] => 98
[menu_item_parent] => 0
[object_id] => 86
[object] => page
[type] => post_type
[type_label] => Page
[url] => http://www.javorszky.co.uk/contact/
[title] => Contact
[target] =>
[attr_title] =>
[description] =>
[classes] => Array
(
[0] =>
[1] => menu-item
[2] => menu-item-type-post_type
[3] => menu-item-object-page
)
[xfn] =>
[current] =>
[current_item_ancestor] =>
[current_item_parent] =>
)
)
[1] =>
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment