. add_theme_support( 'automatic-feed-links' ); // Add support for Post Formats add_theme_support( 'post-formats', array( 'aside', 'image', 'video', 'quote', 'link', 'gallery' ) ); // This theme uses wp_nav_menu() in one location. register_nav_menu( 'primary', __( 'Primary Menu', 'chateau' ) ); // Add support for custom backgrounds add_theme_support( 'custom-background' ); // This theme uses Featured Images (also known as post thumbnails) for per-post/per-page Custom Header images add_theme_support( 'post-thumbnails' ); /* * We'll be using post thumbnails for custom header images on posts and pages. * We want them to be the size of the header image that we just defined * Larger images will be auto-cropped to fit, smaller ones will be ignored. * * See header.php. * See inc/custom-header.php */ set_post_thumbnail_size( 960, 260, true ); } endif; // end chateau_setup /** * Enqueue scripts and styles */ function chateau_scripts() { wp_enqueue_style( 'chateau', get_stylesheet_uri() ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' ); } add_action( 'wp_enqueue_scripts', 'chateau_scripts' ); // Allow custom colors to match the background color of some elements function chateau_custom_background_color() { if ( '' != get_background_color() ) { $custombackgroundcolor = get_background_color(); ?> __( 'Sidebar Widget Area', 'chateau' ), 'id' => 'sidebar', 'description' => __( 'The Sidebar', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'Upper Footer Widget Area', 'chateau' ), 'id' => 'upper-footer-widget-area', 'description' => __( 'A single full-width footer column', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'First Footer Widget Area', 'chateau' ), 'id' => 'first-footer-widget-area', 'description' => __( 'The first column below the Upper Footer Widget Area', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'Second Footer Widget Area', 'chateau' ), 'id' => 'second-footer-widget-area', 'description' => __( 'The second column below the Upper Footer Widget Area', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'Third Footer Widget Area', 'chateau' ), 'id' => 'third-footer-widget-area', 'description' => __( 'The third column below the Upper Footer Widget Area', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); register_sidebar( array( 'name' => __( 'Fourth Footer Widget Area', 'chateau' ), 'id' => 'fourth-footer-widget-area', 'description' => __( 'The fourth column below the Upper Footer Widget Area', 'chateau' ), 'before_widget' => '', 'before_title' => '

', 'after_title' => '

', )); } add_action( 'widgets_init', 'chateau_widgets_init' ); //Changed wp_page_menu structure to get rid of the wrapped div and add menu_class arguments to