51 lines
1.3 KiB
PHP
51 lines
1.3 KiB
PHP
|
<?php
|
||
|
|
||
|
if (function_exists('add_theme_support')) {
|
||
|
// add_theme_support('menus');
|
||
|
|
||
|
add_theme_support('post-thumbnails');
|
||
|
|
||
|
// add_image_size('large', 700, '', true);
|
||
|
// add_image_size('medium', 250, '', true);
|
||
|
// add_image_size('small', 120, '', true);
|
||
|
// add_image_size('custom-size', 700, 200, true); // call using the_post_thumbnail('custom-size');
|
||
|
|
||
|
add_theme_support('automatic-feed-links');
|
||
|
}
|
||
|
|
||
|
function ildi_nav($location='header-menu') {
|
||
|
wp_nav_menu(
|
||
|
array(
|
||
|
'theme_location' => $location,
|
||
|
'menu' => '',
|
||
|
'container' => '',
|
||
|
'container_class' => '',
|
||
|
'container_id' => '',
|
||
|
'menu_class' => $location,
|
||
|
'menu_id' => '',
|
||
|
'echo' => true,
|
||
|
'fallback_cb' => 'wp_page_menu',
|
||
|
'before' => '',
|
||
|
'after' => '',
|
||
|
'link_before' => '',
|
||
|
'link_after' => '',
|
||
|
'items_wrap' => '<ul class="%2$s">%3$s</ul>',
|
||
|
'depth' => 0,
|
||
|
'walker' => ''
|
||
|
)
|
||
|
);
|
||
|
}
|
||
|
|
||
|
function register_ildi_menus() {
|
||
|
register_nav_menus(array(
|
||
|
'header-menu' => __('Header Menu', 'ildi'),
|
||
|
'social-menu' => __('Social Links', 'ildi'),
|
||
|
'footer-menu' => __('Footer Menu', 'ildi')
|
||
|
));
|
||
|
}
|
||
|
|
||
|
|
||
|
// add_action('init', 'register_ildi_menu');
|
||
|
add_action( 'after_setup_theme', 'register_ildi_menus', 0 );
|
||
|
?>
|