/**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function risto_theme_setup()
 {
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /*
      * Let WordPress manage the document title.
      * By adding theme support, we declare that this theme does not use a
      * hard-coded <title> tag in the document head, and expect WordPress to
      * provide it for us.
      */
     add_theme_support('title-tag');
     /*
      * Enable support for Post Thumbnails on posts and pages.
      *
      */
     add_theme_support('post-thumbnails');
     add_image_size('services', 200, 118, true);
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => __('Primary Menu', 'risto-theme'), 'secondary' => __('Secondary Menu', 'risto-theme')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     /*
      * Enable support for Post Formats.
      * See http://codex.wordpress.org/Post_Formats
      */
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link'));
 }
 /**
  * Action on the after_setup_theme hook.
  * Checks to see if the author_pro_archive image size exists
  * then adds author_pro_archive image size if it isn't set.
  * This allows the child theme or another plugin to override the image size.
  *
  * @access public
  * @static
  * @return void
  */
 static function maybe_add_image_size()
 {
     global $_wp_additional_image_sizes;
     if (!isset($_wp_additional_image_sizes['author-pro-image'])) {
         add_image_size('author-pro-image', 360, 570, TRUE);
     }
 }
Example #3
0
/**
 * Initialize Pitch's slide post type
 */
function pitch_slide_init()
{
    $labels = array('name' => _x('Slides', 'post type general name', 'pitch'), 'singular_name' => _x('Slide', 'post type singular name', 'pitch'), 'add_new' => _x('Add New', 'book', 'pitch'), 'add_new_item' => __('Add New Slide', 'pitch'), 'edit_item' => __('Edit Slide', 'pitch'), 'new_item' => __('New Slide', 'pitch'), 'all_items' => __('All Slide', 'pitch'), 'view_item' => __('View Slide', 'pitch'), 'search_items' => __('Search Slides', 'pitch'), 'not_found' => __('No slides found', 'pitch'), 'not_found_in_trash' => __('No slides found in Trash', 'pitch'), 'parent_item_colon' => '', 'menu_name' => __('Slides', 'pitch'));
    $args = array('labels' => $labels, 'public' => false, 'publicly_queryable' => false, 'show_ui' => true, 'show_in_menu' => true, 'query_var' => false, 'rewrite' => false, 'capability_type' => 'post', 'has_archive' => true, 'hierarchical' => false, 'menu_position' => null, 'supports' => array('title', 'thumbnail', 'excerpt', 'page-attributes'), 'menu_icon' => get_template_directory_uri() . '/images/post-types/slider-small.png');
    register_post_type('slide', $args);
    add_image_size('slide', 960, siteorigin_setting('slider_height'), true);
}
Example #4
0
function foundation_featured_setup()
{
    if (function_exists('add_theme_support')) {
        add_theme_support('post-thumbnails');
        add_image_size('foundation-featured-image', 900, 9999, false);
    }
    global $foundation_featured_posts;
    $settings = foundation_get_settings();
    $args = foundation_featured_get_args();
    if ($settings->featured_enabled) {
        $slides = foundation_featured_get_slides();
        $slide_count = 0;
        if ($slides->post_count > 0) {
            while ($slides->have_posts() && $slide_count < $args['num']) {
                $slides->the_post();
                $image = foundation_featured_has_image();
                if ($image) {
                    $slide_count++;
                    $foundation_featured_posts[] = get_the_ID();
                }
            }
        }
    }
    add_filter('parse_query', 'foundation_featured_modify_query');
}
Example #5
0
 /**
  * Initial setup
  *
  * This function is attached to the 'after_setup_theme' action hook.
  *
  * @uses	load_theme_textdomain()
  * @uses	get_locale()
  * @uses	BAVOTASAN_THEME_TEMPLATE
  * @uses	add_theme_support()
  * @uses	add_editor_style()
  * @uses	add_custom_background()
  * @uses	add_custom_image_header()
  * @uses	register_default_headers()
  *
  * @since 1.0.0
  */
 function bavotasan_setup()
 {
     load_theme_textdomain('arcade', BAVOTASAN_THEME_TEMPLATE . '/library/languages');
     // Add default posts and comments RSS feed links to <head>.
     add_theme_support('automatic-feed-links');
     // This theme styles the visual editor with editor-style.css to match the theme style.
     add_editor_style('library/css/admin/editor-style.css');
     // This theme uses wp_nav_menu() in two location.
     register_nav_menu('primary', __('Primary Menu', 'arcade'));
     // Add support for a variety of post formats
     add_theme_support('post-formats', array('gallery', 'image', 'video', 'audio', 'quote', 'link', 'status', 'aside'));
     // This theme uses Featured Images (also known as post thumbnails) for archive pages
     add_theme_support('post-thumbnails');
     add_image_size('half', 570, 220, true);
     add_image_size('square100', 100, 100, true);
     // Add a filter to bavotasan_header_image_width and bavotasan_header_image_height to change the width and height of your custom header.
     add_theme_support('custom-header', array('header-text' => false, 'flex-height' => true, 'flex-width' => true, 'random-default' => true, 'width' => apply_filters('bavotasan_header_image_width', 1800), 'height' => apply_filters('bavotasan_header_image_height', 1200)));
     // Default custom headers packaged with the theme. %s is a placeholder for the theme template directory URI.
     register_default_headers(array('header01' => array('url' => '%s/library/images/header01.jpg', 'thumbnail_url' => '%s/library/images/header01-thumbnail.jpg', 'description' => __('Default Header 1', 'arcade'))));
     // Add support for custom backgrounds
     add_theme_support('custom-background');
     // Add HTML5 elements
     add_theme_support('html5', array('comment-list', 'comment-form'));
     // Add title tag support
     add_theme_support('title-tag');
     // Remove default gallery styles
     add_filter('use_default_gallery_style', '__return_false');
     // Infinite scroll
     add_theme_support('infinite-scroll', array('type' => 'scroll', 'container' => 'primary', 'wrapper' => false, 'footer' => false));
     // Add Woocommerce support
     add_theme_support('woocommerce');
 }
 function theme_setup()
 {
     /* This theme uses post thumbnails (aka "featured images")
      *  all images will be cropped to thumbnail size (below), as well as
      *  a square size (also below). You can add more of your own crop
      *  sizes with add_image_size. */
     add_theme_support('post-thumbnails');
     set_post_thumbnail_size(120, 90, true);
     add_image_size('square', 380, 380, true);
     add_image_size('small-square', 185, 185, true);
     add_image_size('half', 640, 640, true);
     add_image_size('post', 600, 600, true);
     add_image_size('about', 400, 566, true);
     add_image_size('single-post', 600, 600, true);
     // Add default posts and comments RSS feed links to head
     add_theme_support('automatic-feed-links');
     /* This theme uses wp_nav_menu() in one location.
      * You can allow clients to create multiple menus by
      * adding additional menus to the array. */
     register_nav_menus(array('primary' => 'Primary Navigation'));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
 }
Example #7
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function eryn_setup()
 {
     /*
      * Make theme available for translation.
      * Translations can be filed in the /languages/ directory.
      * If you're building a theme based on eryn, use a find and replace
      * to change 'eryn' to the name of your theme in all the template files
      */
     load_theme_textdomain('eryn', get_template_directory() . '/languages');
     // Feed Links
     add_theme_support('automatic-feed-links');
     // Post formats
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link', 'gallery'));
     // Post thumbnails
     add_theme_support('post-thumbnails');
     add_image_size('full-thumb', 940, 0, true);
     add_image_size('slider-thumb', 650, 440, true);
     add_image_size('thumb', 440, 294, true);
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => __('Primary Menu', 'eryn')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     // Display Title in theme
     add_theme_support('title-tag');
     // Custom Backgrounds Support
     $args = array('default-color' => 'FFFFFF');
     add_theme_support('custom-background', $args);
     // link a custom stylesheet file to the TinyMCE visual editor
     $font_url = str_replace(',', '%2C', '//fonts.googleapis.com/css?family=Droid+Serif');
     add_editor_style(array('style.css', 'css/editor-style.css', $font_url));
 }
 function nimbus_setup()
 {
     // Localization
     $lang_local = get_template_directory() . '/lang';
     load_theme_textdomain('nimbus', $lang_local);
     // Register Thumbnail Sizes
     add_theme_support('post-thumbnails');
     set_post_thumbnail_size(1160, 9999, true);
     add_image_size('nimbus-small', 140, 90, true);
     add_image_size('nimbus-feature', 370, 191, true);
     add_image_size('nimbus-post', 760, 227, true);
     add_image_size('nimbus-post-full', 1160, 221, true);
     add_image_size('full-banner', 1160, 360, true);
     add_image_size('half-banner', 660, 360, true);
     add_image_size('half-image', 670, 424, true);
     add_image_size('full-image', 1170, 424, true);
     // Load feed links
     add_theme_support('automatic-feed-links');
     // Support Custom Background
     $nimbus_custom_background_defaults = array('default-color' => 'ffffff');
     add_theme_support('custom-background', $nimbus_custom_background_defaults);
     // Set Content Width
     global $content_width;
     if (!isset($content_width)) {
         $content_width = 770;
     }
     // Register Menus
     register_nav_menu('primary', __('Primary Menu', 'nimbus'));
     register_nav_menu('mobile', __('Mobile Menu', 'nimbus'));
 }
Example #9
0
/**
 * Registers custom image sizes for the theme.
 *
 * @since  1.0.0
 * @access public
 * @return void
 */
function saga_register_image_sizes()
{
    /* Sets the 'post-thumbnail' size. */
    set_post_thumbnail_size(175, 119, true);
    /* Adds the 'saga-large' image size. */
    add_image_size('saga-large', 1100, 9999, false);
}
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which runs
  * before the init hook. The init hook is too late for some features, such as indicating
  * support post thumbnails.
  *
  * @since untitled 1.0
  */
 function untitled_setup()
 {
     /**
      * Make theme available for translation
      * Translations can be filed in the /languages/ directory
      * If you're building a theme based on untitled, use a find and replace
      * to change 'untitled' to the name of your theme in all the template files
      */
     load_theme_textdomain('untitled', get_template_directory() . '/languages');
     /**
      * Add default posts and comments RSS feed links to head
      */
     add_theme_support('automatic-feed-links');
     /**
      * Enable support for Post Thumbnails
      */
     add_theme_support('post-thumbnails', array('post', 'page'));
     set_post_thumbnail_size(150, 150);
     add_image_size('slider-img', 1440, 400, true);
     add_image_size('content-img', 300, 168, true);
     add_image_size('thumbnail-img', 62, 62, true);
     add_image_size('feat-img', 1000);
     /**
      * This theme uses wp_nav_menu() in one location.
      */
     register_nav_menus(array('primary' => __('Primary Menu', 'untitled')));
     /**
      * Enable support for Post Formats
      */
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link'));
 }
function singolo_images_size()
{
    add_image_size('slider', 1020, 600, true);
    add_image_size('project-thumb', 200, 190, true);
    add_image_size('medium', 300, 300, true);
    add_image_size('services', 60, 60, true);
}
Example #12
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function sensible_setup()
 {
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /*
      * Let WordPress manage the document title.
      * By adding theme support, we declare that this theme does not use a
      * hard-coded <title> tag in the document head, and expect WordPress to
      * provide it for us.
      */
     add_theme_support('title-tag');
     /*
      * 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');
     add_image_size('home-blog', 400, 250, true);
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => __('Primary Menu', 'sensible'), 'mobile' => esc_html__('Mobile', 'sensible')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     // Set up the WordPress core custom background feature.
     add_theme_support('custom-background', apply_filters('sensible_custom_background_args', array('default-color' => 'ffffff', 'default-image' => '')));
 }
Example #13
0
 function my_setup()
 {
     // This theme styles the visual editor with editor-style.css to match the theme style.
     add_editor_style();
     // This theme uses post thumbnails
     if (function_exists('add_theme_support')) {
         // Added in 2.9
         add_theme_support('post-thumbnails');
         set_post_thumbnail_size(235, 148, true);
         // Normal post thumbnails
         add_image_size('post-thumbnail-xl', 578, 250, true);
         // Portfolio Extra Large Thumbnail
         add_image_size('portfolio-post-thumbnail', 268, 168, true);
         // Portfolio Thumbnail
         add_image_size('portfolio-post-thumbnail-small', 196, 148, true);
         // Portfolio Small Thumbnail
         add_image_size('portfolio-post-thumbnail-large', 417, 208, true);
         // Portfolio Large Thumbnail
         add_image_size('portfolio-post-thumbnail-xl', 498, 238, true);
         // Portfolio Extra Large Thumbnail
         add_image_size('small-post-thumbnail', 139, 139, true);
         // Small Thumbnail
     }
     // Add default posts and comments RSS feed links to head
     add_theme_support('automatic-feed-links');
     // custom menu support
     add_theme_support('menus');
     if (function_exists('register_nav_menus')) {
         register_nav_menus(array('header_menu' => 'Header Menu'));
     }
 }
/**
 * Theme setup
 */
function setup()
{
    // Make theme available for translation
    load_theme_textdomain('boilerplate', get_template_directory() . '/assets/languages');
    // Enable plugins to manage the document title
    // http://codex.wordpress.org/Function_Reference/add_theme_support#Title_Tag
    add_theme_support('title-tag');
    // Register wp_nav_menu() menus
    // http://codex.wordpress.org/Function_Reference/register_nav_menus
    register_nav_menus(['nav-primary' => _x('Primary Navigation', 'primary site nav menu', 'boilerplate'), 'nav-footer' => _x('Footer Navigation', 'footer site nav menu', 'boilerplate')]);
    // Add post thumbnails
    // http://codex.wordpress.org/Post_Thumbnails
    // http://codex.wordpress.org/Function_Reference/set_post_thumbnail_size
    // http://codex.wordpress.org/Function_Reference/add_image_size
    add_theme_support('post-thumbnails');
    add_image_size('boilerplate-vignette', 300, 250, true);
    // Add post formats
    // http://codex.wordpress.org/Post_Formats
    # add_theme_support('post-formats', ['aside', 'gallery', 'link', 'image', 'quote', 'video', 'audio']);
    // Add HTML5 markup for captions
    // http://codex.wordpress.org/Function_Reference/add_theme_support#HTML5
    add_theme_support('html5', ['caption', 'comment-form', 'comment-list']);
    // Tell the TinyMCE editor to use a custom stylesheet
    # add_editor_style( 'assets/styles/dist/editor.css' );
}
Example #15
0
 function portfilo_portfolio_theme_setup()
 {
     add_theme_support('title-tag');
     add_theme_support('custom-background');
     $args = array('flex-width' => true, 'width' => 1400, 'flex-height' => true, 'height' => 600, 'default-image' => get_template_directory_uri() . '/images/overlay.jpg');
     add_theme_support('custom-header', $args);
     /* ---------------------------------------------------------------------------
      * Loads Theme Textdomain
      * --------------------------------------------------------------------------- */
     load_theme_textdomain('portfilo', PORTFILO_LANG_DIR);
     add_theme_support('automatic-feed-links');
     add_theme_support('woocommerce');
     add_theme_support('post-thumbnails');
     set_post_thumbnail_size(260, 146, false);
     // admin - featured image
     add_image_size('portfilo_50x50', 50, 50, false);
     // admin - lists
     add_image_size('portfilo-aboutus-thumbnail', 1140, 640, true);
     add_image_size('portfilo-blog-listing-thumbnail', 458, 244, true);
     add_image_size('portfilo-blog-detail-thumbnail', 750, 400, true);
     add_image_size('portfilo-slider-thumbnail', 1400, 786, true);
     /* ---------------------------------------------------------------------------
      * Registers a menu location to use with navigation menus.
      * --------------------------------------------------------------------------- */
     /*register_nav_menu('primary', __('Main menu', 'portfilo'));
       register_nav_menu('footer', __('Footer menu', 'portfilo'));*/
     register_nav_menus(array('primary' => __('Primary Navigation', 'portfilo'), 'secondary' => __('Secondary Navigation', 'portfilo')));
     add_action('add_meta_boxes', 'portfilo_Slider');
     add_action('save_post', 'PortfiloSaveHomePageSlider');
 }
Example #16
0
function selfie_setup()
{
    //	Theme TextDomain for the Language File
    load_theme_textdomain('selfie', get_template_directory() . '/languages');
    // 	Theme Menus
    register_nav_menus(array('main-menu' => __('Main Menu', 'selfie'), 'top-menu' => __('Top Menu', 'selfie')));
    //	Set the content width based on the theme's design and stylesheet.
    global $content_width;
    if (!isset($content_width)) {
        $content_width = 584;
    }
    // 	Tell WordPress for the Feed Link
    add_theme_support('automatic-feed-links');
    add_editor_style();
    // 	This theme uses Featured Images (also known as post thumbnails) for per-post/per-page Custom Header images
    add_theme_support('post-thumbnails');
    set_post_thumbnail_size(150, 150, true);
    // default Post Thumbnail dimensions (cropped)
    add_image_size('fpage-thumb', 1000, 500, true);
    // 	WordPress 3.4 Custom Background Support
    $selfie_custom_background = array('default-color' => 'FFFFFF', 'default-image' => '');
    add_theme_support('custom-background', $selfie_custom_background);
    // 	WordPress 3.4 Custom Header Support
    $selfie_custom_header = array('default-image' => get_template_directory_uri() . '/images/logo.png', 'random-default' => false, 'width' => 300, 'height' => 90, 'flex-height' => false, 'flex-width' => false, 'default-text-color' => '0a96d8', 'header-text' => false, 'uploads' => true, 'wp-head-callback' => '', 'admin-head-callback' => '', 'admin-preview-callback' => '');
    add_theme_support('custom-header', $selfie_custom_header);
}
Example #17
0
/**
 * Sets up theme defaults and registers support for various WordPress features.
 *
 * Note that this function is hooked into the after_setup_theme hook, which
 * runs before the init hook. The init hook is too late for some features, such
 * as indicating support for post thumbnails.
 */
function goran_setup()
{
    /*
     * Declare textdomain for this child theme.
     */
    load_child_theme_textdomain('goran', get_stylesheet_directory() . '/languages');
    /*
     * Enable support for Post Thumbnails on posts and pages.
     *
     * @link http://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails
     */
    add_image_size('edin-thumbnail-landscape', 314, 228, true);
    add_image_size('edin-thumbnail-square', 314, 314, true);
    add_image_size('edin-featured-image', 772, 9999);
    add_image_size('edin-hero', 1230, 1230);
    /*
     * Unregister nav menu.
     */
    unregister_nav_menu('secondary');
    /*
     * Editor styles.
     */
    add_editor_style(array('editor-style.css', goran_noto_sans_font_url(), goran_noto_serif_font_url(), goran_droid_sans_mono_font_url()));
    /**
     * Add support for Eventbrite.
     * See: https://wordpress.org/plugins/eventbrite-api/
     */
    add_theme_support('eventbrite');
}
Example #18
0
 function eminent_setup()
 {
     // This theme uses wp_nav_menu() in one locations.
     register_nav_menus(array('primary' => __('Main Menu', 'eminent')));
     global $eminent_content_width;
     if (!isset($content_width)) {
         $content_width = 900;
     }
     /*
      * Make eminent theme available for translation.
      */
     load_theme_textdomain('eminent', get_template_directory() . '/languages');
     // This theme styles the visual editor to resemble the theme style.
     add_editor_style(array('css/editor-style.css', eminent_font_url()));
     // Add RSS feed links to <head> for posts and comments.
     add_theme_support('automatic-feed-links');
     add_theme_support('title-tag');
     add_theme_support('post-thumbnails');
     set_post_thumbnail_size(770, 350, true);
     add_image_size('eminent-blog-thumbnail-image', 770, 400, true);
     add_image_size('eminent-blog-thumbnail-image-home', 370, 263, true);
     /*        
      * Switch default core markup for search form, comment form, and comments        
      * to output valid HTML5.        
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list'));
     // Add support for featured content.
     add_theme_support('featured-content', array('featured_content_filter' => 'eminent_get_featured_posts', 'max_posts' => 6));
     add_theme_support('custom-header', apply_filters('eminent_custom_header_args', array('uploads' => true, 'flex-height' => true, 'default-text-color' => '#e36229', 'header-text' => true, 'height' => '120', 'width' => '1260')));
     add_theme_support('custom-background', apply_filters('eminent_custom_background_args', array('default-color' => 'f5f5f5')));
     // This theme uses its own gallery styles.
     add_filter('use_default_gallery_style', '__return_false');
 }
Example #19
0
/**
*
* THEME SETUP
*
**/
function SkeletonTube_Setup()
{
    /**
     *
     * Navigation Menu
     *
     **/
    register_nav_menus(array('primary' => __('Primary Menu'), 'footer' => __('Footer Menu')));
    /**
     *
     * Add featured image support
     *
     **/
    add_theme_support('post-thumbnails');
    add_image_size('banner-image', 950, 350, true);
    /**
     *
     * Search Form
     *
     **/
    add_theme_support('html5', array('search-form'));
    /**
     *
     * Add Post Format Support
     *
     **/
    add_theme_support('post-formats', array('aside', 'gallery', 'link'));
}
 /**
  * Setup Origami.
  * 
  * @action after_setup_theme
  */
 function origami_setup()
 {
     so_settings_init();
     global $content_width;
     if (!isset($content_width)) {
         $content_width = 904;
     }
     // Load the text domains
     load_theme_textdomain('origami', get_template_directory() . '/languages');
     add_theme_support('automatic-feed-links');
     // Origami supports post formats
     add_theme_support('post-formats', array('gallery', 'image', 'video', 'aside', 'link', 'quote', 'status', 'chat'));
     // Origami supports post thumbnails
     add_theme_support('post-thumbnails');
     // Create the primary menu area
     register_nav_menu('primary', 'Primary Menu');
     // Add support for custom backgrounds.
     add_theme_support('custom-background', array('default-color' => 'f0eeeb', 'default-image' => get_template_directory_uri() . '/images/bg.png'));
     // Use custom headers for site logo
     add_theme_support('custom-header', array('flex-height' => true, 'flex-width' => true, 'header-text' => false));
     add_editor_style();
     // Set up the image sizes
     set_post_thumbnail_size(904, 400, true);
     add_image_size('post-thumbnail-mobile', 480, 420, true);
     add_image_size('post-thumbnail-full', 904, 904, false);
     add_image_size('origami-slider', 904, 500, true);
 }
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function _act_setup()
 {
     load_theme_textdomain('_s', get_template_directory() . '/languages');
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     add_theme_support('title-tag');
     /*
      * Enable support for Post Thumbnails on posts and pages.
      *
      * @link https://developer.wordpress.org/themes/functionality/featured-images-post-thumbnails/
      */
     add_theme_support('post-thumbnails');
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => esc_html__('Primary', '_act'), 'hero' => esc_html__('Hero', '_act')));
     /*
      * Switch default core markup for search form, comment form, and comments
      * to output valid HTML5.
      */
     add_theme_support('html5', array('search-form', 'comment-form', 'comment-list', 'gallery', 'caption'));
     /*
      * Enable support for Post Formats.
      * See https://developer.wordpress.org/themes/functionality/post-formats/
      */
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link'));
     // Set up the WordPress core custom background feature.
     add_theme_support('custom-background', apply_filters('_act_custom_background_args', array('default-color' => 'ffffff', 'default-image' => '')));
     add_image_size('feature500', 500, 500, true);
 }
Example #22
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function dazzling_setup()
 {
     /*
      * Make theme available for translation.
      * Translations can be filed in the /languages/ directory.
      * If you're building a theme based on Dazzling, use a find and replace
      * to change 'dazzling' to the name of your theme in all the template files
      */
     load_theme_textdomain('dazzling', get_template_directory() . '/languages');
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /*
      * 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');
     add_image_size('dazzling-featured', 730, 410, true);
     add_image_size('tab-small', 60, 60, true);
     // Small Thumbnail
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => __('Primary Menu', 'dazzling'), 'footer-links' => __('Footer Links', 'dazzling')));
     // Enable support for Post Formats.
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link'));
     // Setup the WordPress core custom background feature.
     add_theme_support('custom-background', apply_filters('dazzling_custom_background_args', array('default-color' => 'ffffff', 'default-image' => '')));
     /*
      * Let WordPress manage the document title.
      * By adding theme support, we declare that this theme does not use a
      * hard-coded <title> tag in the document head, and expect WordPress to
      * provide it for us.
      */
     add_theme_support('title-tag');
 }
Example #23
0
function _tm_register_image_sizes()
{
    if (!current_theme_supports('post-thumbnails')) {
        return;
    }
    set_post_thumbnail_size(238, 182, true);
    // Registers a new image sizes.
    add_image_size('_tm-thumb-s', 150, 150, true);
    add_image_size('_tm-thumb-240-100', 240, 100, true);
    add_image_size('_tm-thumb-m', 400, 400, true);
    add_image_size('_tm-thumb-560-350', 560, 350, true);
    add_image_size('_tm-post-thumbnail-large', 770, 480, true);
    add_image_size('_tm-thumb-l', 1170, 780, true);
    add_image_size('_tm-thumb-xl', 1920, 1080, true);
    add_image_size('_tm-thumb-150-115', 150, 115, true);
    add_image_size('_tm-thumb-238-182', 238, 182, true);
    add_image_size('_tm-thumb-337-258', 337, 258, true);
    add_image_size('_tm-thumb-476-365', 476, 365, true);
    add_image_size('_tm-thumb-536-411', 536, 411, true);
    add_image_size('_tm-thumb-426-327', 426, 327, true);
    add_image_size('_tm-thumb-860-662', 860, 662, true);
    add_image_size('_tm-thumb-760-585', 760, 585, true);
    add_image_size('_tm-thumb-660-508', 660, 508, true);
    add_image_size('_tm-thumb-1132-411', 1132, 411, true);
}
Example #24
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function my_simone_setup()
 {
     /*
      * Make theme available for translation.
      * Translations can be filed in the /languages/ directory.
      * If you're building a theme based on my-simone, use a find and replace
      * to change 'my-simone' to the name of your theme in all the template files
      */
     load_theme_textdomain('my-simone', get_template_directory() . '/languages');
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /*
      * 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');
     add_image_size('large-thumb', 1060, 650, true);
     add_image_size('index-thumb', 780, 250, true);
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => __('Primary Menu', 'my-simone'), 'social' => __('Social Menu', 'my-simone')));
     // Enable support for Post Formats.
     add_theme_support('post-formats', array('aside'));
     // Setup the WordPress core custom background feature.
     //	add_theme_support( 'custom-background', apply_filters( 'my_simone_custom_background_args', array(
     //		'default-color' => 'ffffff',
     //		'default-image' => '',
     //	) ) );
     // Enable support for HTML5 markup.
     add_theme_support('html5', array('comment-list', 'search-form', 'comment-form', 'gallery', 'caption'));
 }
Example #25
0
function Destro_setup()
{
    // This theme uses wp_nav_menu() in one location.
    register_nav_menus(array('mainmenu' => __('Main Navigation', 'Destro')));
    // This theme uses post thumbnails
    add_theme_support('post-thumbnails');
    add_image_size('Destrothumb', 450, 300, true);
    // Add default posts and comments RSS feed links to head
    add_theme_support('automatic-feed-links');
    // Add translation support
    load_theme_textdomain('Destro', get_template_directory() . '/languages');
    // Delete default WordPress gallery css
    add_filter('use_default_gallery_style', '__return_false');
    // Add Custom background feature
    if (of_get_option('skin_style')) {
        $custombgargsskin = of_get_option('skin_style');
    } else {
        $custombgargsskin = 'destro';
    }
    if (get_stylesheet_directory() == get_template_directory()) {
        $custombgargs = array('default-color' => '292929', 'default-image' => get_template_directory_uri() . '/images/' . $custombgargsskin . '/page_bg.png');
    } else {
        $custombgargs = array('default-image' => get_stylesheet_directory_uri() . '/images/page_bg.png');
    }
    add_theme_support('custom-background', $custombgargs);
}
Example #26
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which runs
  * before the init hook. The init hook is too late for some features, such as indicating
  * support post thumbnails.
  *
  * To override foghorn_setup() in a child theme, add your own foghorn_setup to your child theme's
  * functions.php file.
  *
  * @uses load_theme_textdomain() For translation/localization support.
  * @uses add_editor_style() To style the visual editor.
  * @uses add_theme_support() To add support for post thumbnails and automatic feed links.
  * @uses register_nav_menus() To add support for navigation menus.
  * @uses add_custom_background() To add support for a custom background.
  * @uses set_post_thumbnail_size() To set a custom post thumbnail size.
  *
  * @since Foghorn 0.1
  */
 function foghorn_setup()
 {
     /**
      * Set the content width based on the theme's design and stylesheet.
      */
     if (!isset($content_width)) {
         $content_width = 560;
     }
     // Make Foghorn translatable
     load_theme_textdomain('foghorn', TEMPLATEPATH . '/languages');
     $locale = get_locale();
     $locale_file = TEMPLATEPATH . "/languages/{$locale}.php";
     if (is_readable($locale_file)) {
         require_once $locale_file;
     }
     // Styles the visual editor with editor-style.css to match the theme style
     add_editor_style();
     // Add default posts and comments RSS feed links to <head>.
     add_theme_support('automatic-feed-links');
     // This theme uses wp_nav_menu() in one location.
     register_nav_menu('primary', __('Primary Menu', 'foghorn'));
     // Adds support for custom backgrounds
     add_custom_background();
     // Adds theme support for thumbnails
     add_theme_support('post-thumbnails');
     // Creates an image thumbnail size for multiple displays
     add_image_size('multiple-thumb', 325, 205, true);
     // Sets up the option panel functions
     require_once TEMPLATEPATH . '/extensions/options-functions.php';
 }
Example #27
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function activello_setup()
 {
     /*
      * Make theme available for translation.
      * Translations can be filed in the /languages/ directory.
      */
     load_theme_textdomain('activello', get_template_directory() . '/languages');
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /**
      * 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');
     add_image_size('activello-featured', 1170, 550, true);
     add_image_size('activello-slider', 1920, 550, true);
     add_image_size('activello-thumbnail', 330, 220, true);
     add_image_size('activello-medium', 640, 480, true);
     // This theme uses wp_nav_menu() in one location.
     register_nav_menus(array('primary' => esc_html__('Primary Menu', 'activello')));
     // Enable support for Post Formats.
     add_theme_support('post-formats', array('video', 'audio'));
     // Setup the WordPress core custom background feature.
     add_theme_support('custom-background', apply_filters('activello_custom_background_args', array('default-color' => 'FFFFFF', 'default-image' => '')));
     // Enable support for HTML5 markup.
     add_theme_support('html5', array('comment-list', 'search-form', 'comment-form', 'gallery', 'caption'));
     /*
      * Let WordPress manage the document title.
      * By adding theme support, we declare that this theme does not use a
      * hard-coded <title> tag in the document head, and expect WordPress to
      * provide it for us.
      */
     add_theme_support('title-tag');
 }
Example #28
0
 function sf_dante_setup()
 {
     /* THEME SUPPORT
     			================================================== */
     add_theme_support('structured-post-formats', array('audio', 'gallery', 'image', 'link', 'video'));
     add_theme_support('post-formats', array('aside', 'chat', 'quote', 'status'));
     add_theme_support('automatic-feed-links');
     add_theme_support('post-thumbnails');
     add_theme_support('woocommerce');
     /* THUMBNAIL SIZES
     			================================================== */
     set_post_thumbnail_size(220, 150, true);
     add_image_size('widget-image', 94, 70, true);
     add_image_size('thumb-square', 250, 250, true);
     add_image_size('thumb-image', 600, 450, true);
     add_image_size('thumb-image-twocol', 900, 675, true);
     add_image_size('thumb-image-onecol', 1800, 1200, true);
     add_image_size('blog-image', 1280, 9999);
     add_image_size('full-width-image-gallery', 1280, 720, true);
     /* CONTENT WIDTH
     			================================================== */
     if (!isset($content_width)) {
         $content_width = 1140;
     }
     /* LOAD THEME LANGUAGE
     			================================================== */
     load_theme_textdomain('swiftframework', SF_TEMPLATE_PATH . '/language');
 }
	function my_setup() {
		// This theme styles the visual editor with editor-style.css to match the theme style.
		add_editor_style();

		// This theme uses post thumbnails
		if ( function_exists( 'add_theme_support' ) ) { // Added in 2.9
			add_theme_support( 'post-thumbnails' );
			set_post_thumbnail_size( 200, 150, true ); // Normal post thumbnails
			add_image_size( 'slider-post-thumbnail', 940, 446, true ); // Slider Thumbnail
			add_image_size( 'slider-thumb', 100, 50, true ); // Slider Small Thumbnail
		}

		// Add default posts and comments RSS feed links to head
		add_theme_support( 'automatic-feed-links' );

		// custom menu support
		add_theme_support( 'menus' );
		if ( function_exists( 'register_nav_menus' ) ) {
			register_nav_menus(
				array(
					'header_menu' => theme_locals("header_menu"),
					'footer_menu' => theme_locals("footer_menu")
				)
			);
		}
	}
Example #30
0
 /**
  * Sets up theme defaults and registers support for various WordPress features.
  *
  * Note that this function is hooked into the after_setup_theme hook, which
  * runs before the init hook. The init hook is too late for some features, such
  * as indicating support for post thumbnails.
  */
 function fictive_setup()
 {
     /*
      * Make theme available for translation.
      * Translations can be filed in the /languages/ directory.
      * If you're building a theme based on Fictive, use a find and replace
      * to change 'fictive' to the name of your theme in all the template files
      */
     load_theme_textdomain('fictive', get_template_directory() . '/languages');
     // Add default posts and comments RSS feed links to head.
     add_theme_support('automatic-feed-links');
     /*
      * Enable support for Post Thumbnails on posts and pages.
      */
     add_theme_support('post-thumbnails', array('post', 'page'));
     add_image_size('fictive-index-thumb', 816, 999);
     // This theme uses wp_nav_menu() in two locations.
     register_nav_menus(array('primary' => __('Primary Menu', 'fictive'), 'social' => __('Social Links', 'fictive')));
     // Enable support for Post Formats.
     add_theme_support('post-formats', array('aside', 'image', 'video', 'quote', 'link', 'audio', 'gallery', 'status'));
     // Setup the WordPress core custom background feature.
     add_theme_support('custom-background', apply_filters('fictive_custom_background_args', array('default-color' => 'efedea')));
     // Enable support for HTML5 markup.
     add_theme_support('html5', array('comment-list', 'search-form', 'comment-form', 'gallery'));
     /**
      * Add support for Eventbrite.
      * See: https://wordpress.org/plugins/eventbrite-api/
      */
     add_theme_support('eventbrite');
 }