Only show top-level links in site navigation

Had you tried depth argument (see wp_nav_menu() documentation)? Also do I understand right that you do not setup menu manually and let theme generate it with custom callback that you have in your code? Update Same answer – try depth argument, only this time in wp_list_pages() call in starkers_menu() function. It should work, unless that … Read more

Paging doesn’t work?

Answered a question that’s virtually identical to this very recently on the WordPress.org forums. Custom Post Type Archive Page – Pagination Isn’t Working I’ve provided a work-around / fix in that thread that should also work for you to. 🙂 EDIT: You also need to add the paging parameter to your query.. Eg. $args = … Read more

Fallback_cb is messing around with containers

basically you are missing the container div so if you change your fallback to a custom function you can pass parameters to wp_page_menu that give you a bit of control over it and add your missing div try: $wp_nav_header = array( ‘container’ => ”, ‘menu_class’ => ‘sf-menu’, ‘fallback_cb’ => ‘my_fallback_menu’, ‘theme_location’ => ‘primaryheader’, ‘depth’ => … Read more

Custom markup with wp_nav_menu based on pages

The only way that I could think to do this would be to add a filter to wp_nav_menu_items. Here is the code that I got to work (just add it to your themes functions.php file): add_filter(‘wp_nav_menu_items’, ‘my_id_name_nav’, 10, 2); function my_id_name_nav($items,$args) { if( $args->theme_location == ‘primary’ ) { preg_match_all(‘/<li id=”menu-item-([0-9]+)”([^>]+)>\s*<a href=”https://wordpress.stackexchange.com/questions/13867/([^”]+)”>([^<]+)<\/a><\/li>/i’, $items, $matches); $newItems = … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)