badget

Biggest Sale! Special Offer!

Get 30% discount on all of our single themes with this coupon code: #30%SALE

Hurry up! *Limited time offer*

Slider Height

Tagged: 

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #20448
    Carol
    Participant

    Hello – How do I change the height of the slider?

    Thank You – Carol

    #20480

    Hi Carol,
    Before making any changes in our theme first of all you need to create a child theme to be safe from your code lost. So you need to create a child theme then only customise the code.
    Go to theme folder -> functions.php on line no 157 and 158 and you will find this code

    	add_image_size( 'slider-narrow', 1038, 500, true ); // used on Featured Slider on Homepage Header for narrow layout
    	add_image_size( 'slider-wide', 1440, 500, true ); // used on Featured Slider on Homepage Header for wide layout
    

    Then change the image slider size you want. (e.g:- for slider wide 1440 is width and 500 is height)
    You may change this numeric value according to your need.

    Thank you!

    #20647
    Carol
    Participant

    Hi This did not work and I will assume I am doing something wrong. 🙂

    This is the Functions code in my child themes folder via Blue Host, and/or the functions.php on the backend of my child theme in the editor under appearance.

    ……………….

    <?php
    // Exit if accessed directly
    if ( !defined( ‘ABSPATH’ ) ) exit;

    // BEGIN ENQUEUE PARENT ACTION

    if ( !function_exists( ‘chld_thm_cfg_parent_css’ ) ):
    function chld_thm_cfg_parent_css() {
    wp_enqueue_style( ‘chld_thm_cfg_parent’, get_template_directory_uri() . ‘/style.css’ );
    }
    endif;
    add_action( ‘wp_enqueue_scripts’, ‘chld_thm_cfg_parent_css’ );

    // END ENQUEUE PARENT ACTION

    ……………………

    Where exactly do I put the new code & how exactly to I put it in?

    I do not know PHP. As you can see…

    Thank You – Carol

    #20770

    Hi Carol,
    Add this below code inside child theme style.css

    /*
    Theme Name: interface Child Theme
    Author: Self-Help WordPress User
    Template: interface
    */
    
    @import url("../interface/style.css"); 

    and under functions.php

    <?php
    
    // Remove the default Thematic blogtitle function
    function remove_interface_core_functionality() {
        remove_action('interface_init', 'interface_core_functionality', 20 );
    }
    // Call 'remove_thematic_actions' (above) during WP initialization
    add_action('init','remove_interface_core_functionality');
    
    add_action( 'interface_init', 'interfacechild_core_functionality', 20 );
    /**
     * Adding the core functionality of WordPess.
     *
     * @since 1.0
     */
    function interfacechild_core_functionality() {
    	/** 
    	 * interfacechild_add_functionality hook
    	 *
    	 * Adding other addtional functionality if needed.
    	 */
    	do_action( 'interfacechild_add_functionality' );
    
    	// Add default posts and comments RSS feed links to head
    	add_theme_support( 'automatic-feed-links' );
    
    	// This theme uses Featured Images (also known as post thumbnails) for per-post/per-page.
    	add_theme_support( 'post-thumbnails' ); 
    		
    	// Remove WordPress version from header for security concern
    	remove_action( 'wp_head', 'wp_generator' );
     
    	// This theme uses wp_nav_menu() in header menu location.
    	register_nav_menu( 'primary', __( 'Primary Menu', 'interface' ) );
    
    	// Add Interface custom image sizes
    	add_image_size( 'featured', 670, 300, true );
    	add_image_size( 'featured-medium', 230, 160, true );
    	add_image_size( 'slider-narrow', 1038, 500, true ); 		// used on Featured Slider on Homepage Header for narrow layout
    	add_image_size( 'slider-wide', 1440, 500, true ); 			// used on Featured Slider on Homepage Header for wide layout
    	add_image_size( 'gallery', 474, 342, true ); 				// used to show gallery all images
    	add_image_size( 'icon', 100, 100, true );						//used for icon on business 
    
    	/**
    	 * This theme supports custom background color and image
    	 */
    	add_theme_support( 'custom-background' );
    
    	// Adding excerpt option box for pages as well
    	add_post_type_support( 'page', 'excerpt' );
    }
    
    ?>

    You may need to regenerate all the images. Use this plugin http://wordpress.org/plugins/regenerate-thumbnails/ to regenerate the images.
    Hope this may help you.

    Thank you!

    #20786
    Carol
    Participant

    I’ll give it a go thank you!

    #20790
    Carol
    Participant

    This did not work, even when I go back the the interface pro version (not the child theme). I make the slider changes in the functions php nothing happens after I save the new code. No matter what I do the slider height will not change. I don’t know…..

    Carol

    #20809

    Hi carol,
    After changing the slider size then you need to regenerate the thumbnail with this plugins
    Use this plugin http://wordpress.org/plugins/regenerate-thumbnails/ to regenerate the images.

    Thank you!

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.