tag in the document head, and expect WordPress to * provide it for us. */ add_theme_support( 'title-tag' ); /* * Enable support for custom logo. * * @link https://codex.wordpress.org/Theme_Logo */ add_theme_support( 'custom-logo', array( 'height' => 400, 'width' => 580, 'flex-height' => true, 'flex-width' => true, 'header-text' => array( 'site-title', 'site-description' ), ) ); /* * Enable support for Post Thumbnails on posts and pages. * * @link http://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails */ add_theme_support( 'post-thumbnails' ); // Theme Image Sizes add_image_size( 'cambium-featured-square', 800, 800, true ); add_image_size( 'cambium-featured-landscape', 800, 600, true ); add_image_size( 'cambium-featured-portrait', 600, 800, true ); // This theme uses wp_nav_menu() in four locations. register_nav_menus( array ( 'header-menu' => esc_html__( 'Header Menu', 'cambium' ), ) ); // This theme styles the visual editor to resemble the theme style. add_editor_style( array ( 'css/editor-style.css', cambium_fonts_url() ) ); /* * Switch default core markup for search form, comment form, and comments * to output valid HTML5. */ add_theme_support( 'html5', array ( 'comment-form', 'comment-list', 'gallery', 'caption' ) ); // Setup the WordPress core custom background feature. add_theme_support( 'custom-background', apply_filters( 'cambium_custom_background_args', array ( 'default-color' => 'fff', 'default-image' => '', ) ) ); } endif; // cambium_setup add_action( 'after_setup_theme', 'cambium_setup' ); /** * Set the content width in pixels, based on the theme's design and stylesheet. * * Priority 0 to make it available to lower priority callbacks. * * @global int $content_width */ function cambium_content_width() { $GLOBALS['content_width'] = apply_filters( 'cambium_content_width', 770 ); } add_action( 'after_setup_theme', 'cambium_content_width', 0 ); /** * Register widget area. * * @link http://codex.wordpress.org/Function_Reference/register_sidebar */ function cambium_widgets_init() { // Widget Areas register_sidebar( array( 'name' => esc_html__( 'Main Sidebar', 'cambium' ), 'id' => 'sidebar-1', 'before_widget' => '', 'before_title' => '