From: Steve Sutton Date: Thu, 13 Nov 2014 21:16:17 +0000 (-0500) Subject: make recursive X-Git-Tag: v1.0.0~82 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=30dbb4e791862cd84243bdde8606edabca7433ff;p=WP-Themes%2FPrestonFeather.git make recursive and fix the menu so only getting one level at a time --- diff --git a/functions.php b/functions.php index 3e0a7c7..5d68994 100755 --- a/functions.php +++ b/functions.php @@ -4,39 +4,35 @@ * * Grab the top level pages and their sub pages as the main navigation */ -function glm_page_menu() +function glm_page_menu($parent = 0, $class = '') { $frontPageId = get_option('page_on_front'); $parents = array(); $pages = get_pages(array( - 'post_type' => 'page', - 'parent' => -1, - 'number' => '', - 'exclude' => $frontPageId + 'post_type' => 'page', + 'parent' => $parent, + 'number' => '', + 'exclude' => $frontPageId, + 'post_status' => 'publish', + 'sort_order' => 'asc', + 'sort_column' => 'menu_order' )); - echo ''; + echo ''."\n"; } + + /** * glm_offcanvas_menu *