New Landing How can we help? Themeforest Theme Support Dante Gallery Image Size

Viewing 8 posts - 1 through 8 (of 8 total)
  • Posted in: Dante
  • #131193
    AlHuda School
    Member
    Post count: 63

    Hi,
    I have started adding pictures to my website gallery section but the problem i am facing is the image gets crop when i upload it. Like for instance Dsc01023 is the original image but when i upload it in my gallery it looks like Dsc01023-1280×720. Kindly tell me how to fix it. This has happened to many pictures in my galleries here is an example of a gallery in which i am facing this issue http://aispk.org/?galleries=sandwich-making
    Looking forward to a prompt reply
    Regards

    Attachments:
    You must be logged in to view attached files.
    #131257
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    Hi

    Add this to your child theme’s functions.php file:

    /* THEME SETUP
    	================================================== */
    	if (!function_exists('sf_dante_setup')) {
    		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');
    			
    		}
    		add_action( 'after_setup_theme', 'sf_dante_setup' );
    	}

    and change

    add_image_size( 'full-width-image-gallery', 1280, 720, true);

    to

    add_image_size( 'full-width-image-gallery', 1280, null, true);

    – Kyle

    #131542
    AlHuda School
    Member
    Post count: 63

    Hi,
    Thanks but doesn’t seem to be working at my end.
    PFA the php code and let me know if i am making any mistake
    Regards

    Attachments:
    You must be logged in to view attached files.
    #131569
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    You will need to regenerate your thumbnails

    – Kyle

    #132385
    AlHuda School
    Member
    Post count: 63

    Do i need to install some plugin for that or there is some other way as well? Please suggest

    #132404
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    Yes the regenerate thumbnails plugin

    – Kyle

    #132454
    AlHuda School
    Member
    Post count: 63

    ok thanks

    #132455
    Kyle – SUPPORT
    Moderator
    Post count: 35880

    No problem

    – Kyle

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.