Skip to content

Instantly share code, notes, and snippets.

@scottnix
Created October 18, 2012 05:21
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 scottnix/3909999 to your computer and use it in GitHub Desktop.
Save scottnix/3909999 to your computer and use it in GitHub Desktop.
Thematic Two Access Menus in Header
// register two additional custom menu slots
function childtheme_register_menus() {
if ( function_exists('register_nav_menu')) {
register_nav_menu('secondary-menu', 'Secondary Menu');
register_nav_menu('tertiary-menu', 'Tertiary Menu');
}
}
add_action('init', 'childtheme_register_menus');
///Top Menu (optional)
function childtheme_access2() { ?>
<div id="access2"> <?php
if ( has_nav_menu( 'secondary-menu' ) ) {
wp_nav_menu( array( 'theme_location' => 'secondary-menu',
'container_id'=>'secondary-menu',
'container_class' => 'clearfix', // I would remove this and add the clearfix through CSS, but I use SASS/Compass to make this easy
'menu_class' => 'sf-menu', // class for dropdowns
) );
}
?> </div> <?php
}
add_action('thematic_header', 'childtheme_access2', 10);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment