Skip to content

Instantly share code, notes, and snippets.

@alegut
Last active July 15, 2018 10:15
Show Gist options
  • Select an option

  • Save alegut/7351ba92837ce4467ccac19acfdc855b to your computer and use it in GitHub Desktop.

Select an option

Save alegut/7351ba92837ce4467ccac19acfdc855b to your computer and use it in GitHub Desktop.
WordPress register navigation menus and image sizes
function univer_features() {
register_nav_menu('headerManuLocation', 'Header Menu Location');
register_nav_menu('footerLocation1', 'Footer Menu Location 1');
register_nav_menu('footerLocation2', 'Footer Menu Location 2');
add_theme_support('title-tag');
add_theme_support('post-thumbnails');
add_image_size('professorLandscape', 400, 260, true);
add_image_size('professorPortrait', 480, 650, true);
add_image_size('pageBanner', 1500, 350, true);
}
add_action('after_setup_theme', 'univer_features');
//Inserting menu
wp_nav_menu(array(
'theme_location' => 'headerManuLocation'
));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment