Tagged: 

Viewing 20 posts - 1 through 20 (of 20 total)
  • Author
    Posts
  • #295108

    Hey guys

    Thanks for the last update; Lightbox is great!

    Well, almost. It seems to default to a smaller image size than I have uploaded. Can the code be changed to diplay the native size of the image upon Lightbox load?

    I need to display 120px wide images but it certainly doesn’t show them that big at the moment.

    Cheers guys – keep up the good work.
    Regards
    Ed

    #295118

    Hi Ed,

    Can you post the link to your website please?

    Regards,
    Josue

    #295134

    Sure, try this:
    http://www.swarez.co.uk

    Try this page and load the Lightbox: Gallery of Purchased Art

    The picture with the sculptured heads looking forward is 1210px x 992px. However when you click to load the Lightbox I get a smaller version (i.e. it doesn’t meet the edge of my 1210px layout). File is called ‘Spirit of the Dance’ and looks like this: http://www.swarez.co.uk/images10/Untitled-2.jpg

    Thanks
    Ed

    #295143

    Hi Ed!

    Have you tried regenerating the thumbnails?
    http://wordpress.org/plugins/regenerate-thumbnails/

    Regards,
    Josue

    #295148

    Hi Josue

    I just regenerated that image alone – now it’s replaced the original file with the 1030x844px version!!! All others remain the original ones. Now I am worried that if I regenerate all images I will get smaller versions defaulting into the lIghtbox which is the opposite of what I want.

    I used to have a code fix that allowed me to change the JS file to tell the Lightbox to display the native image and get rid of the need to use the 1030px version.

    Can that be located please? Is that the solution?

    Your help is appreciated.
    regards
    Ed

    #295154

    Hey!

    Try adding this at the very end of your theme / child theme functions.php file:

    function change_imgsize() {
    	global $avia_config;
    	$avia_config['imgSize']['entry_without_sidebar'] = array('width'=>1600, 'height'=>1600 );
    }
    add_action( 'init', 'change_imgsize', 1000);
    

    Cheers!
    Josue

    #295173

    Hi Josue

    Doesn’t work I’m afraid. Added to functions.php in child theme and nothing. Removed and added to functions.php instead in the main them and it breaks the site.

    Any other ideas?

    Thanks Ed

    #295177

    Hi Ed,

    Did you regenerate the thumbnails after adding that?

    Regards,
    Josue

    #295179

    Hi Josue

    Yes I did a regenerate on that file plus a few new ones on a new Portfolio item that has done the same thing – defaulted to 1033px version not the 1210px original version.

    Regenerated and flushed but no change in Child-Theme functions.php.

    Sorry man

    regards
    Ed

    #295180

    Hi Ed,

    Can you please create me an administrator account? post it here as a private reply.

    Regards,
    Josue

    #295182

    I am looking all over the site in detail now and there are plenty of over-sized images but NONE will go bigger than 1033px so it seems. Is there a parameter or event handler that defines the maximum width of a displayed image in Lightbox?

    Just a thought if it helps…

    Cheers
    Ed

    #295191
    This reply has been marked as private.
    #295215

    Fixed:
    http://www.swarez.co.uk/gallery-commissioned-purchased-art/

    Added this to child functions.php:

    function change_masonry_gallery_imgsize() {
    	return "full";
    }
    add_filter('avf_avia_builder_masonry_lightbox_img_size', 'change_masonry_gallery_imgsize');
    #295222

    Thanks Josue

    I have checked a few random images and they look fine; just a pity some have defaulted to only loading the 1030px versions – guess that one will remain a mystery.

    Thanks for your help
    Regards
    Ed

    #295223

    I made a quick check and all images from the masonry are apparently linking to their full versions as expected, but perhaps its something related to the caching plugin you have activated.

    Cheers!
    Josue

    #295228

    Thankyou… That is correct for Masonry but the problem remains on Galleries.

    This is not linking to the full version: http://www.swarez.co.uk/wp-content/uploads/2014/07/Black-painted-horizontal-lines.jpg – it links to: http://www.swarez.co.uk/wp-content/uploads/2014/07/Black-painted-horizontal-lines-1030×686.jpg and is on this page: http://www.swarez.co.uk/modern-art-paintings-for-sale/paper-plane/

    Cache flushed and cleared.

    Is this the same issue?

    Cheers
    Ed

    #295230

    Hi Ed!

    Check it now:
    http://www.swarez.co.uk/modern-art-paintings-for-sale/paper-plane/

    Added this to child functions.php:

    function avia_change_gallery_thumbnail_link($link, $attachment, $atts, $meta) {
        $link = wp_get_attachment_image_src($attachment->ID, "full");
        return $link;
    }
    add_filter('avf_avia_builder_gallery_image_link', 'avia_change_gallery_thumbnail_link', 10, 4);
    

    Cheers!
    Josue

    #295305

    Hi Josue

    My hero! Thank you so very much!

    You saved the day again!

    Huge thanks to you my friend.

    Best wishes
    Ed

    #295309

    You are welcome Ed, your work is awesome :)

    Regards,
    Josue

    #295317

    Wow! Thanks man; that’s a very cool thing to say! Although I seem to spend more time with my site that I do painting!

    But grateful for the feedback Josue, thankyou…

Viewing 20 posts - 1 through 20 (of 20 total)
  • The topic ‘Lightbox Image Size’ is closed to new replies.