Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
  • #4874
    Joseph Skelley

    Hi guys, hope you’re all well.

    I’m having a couple of issues with using any kind of lightbox gallery on the site below.

    For some reason, the first couple of images in any gallery are really slow to load.

    If I scroll across a few images, they load quicker – and when I go backwards (using arrow keys) the first images load slowly, or not at all.

    Any ideas why this may be happening.

    Bit of a noob with all this, so any help is greatly appreciated. Thank you.


    I looked at your site and everything seems to work perfectly.

    Image load time depends on the image file size. The images previously viewed show up faster because it’s already on your hard drive – it’s not being loaded again.

    Joseph Skelley

    Thanks for taking a look Bartosz. It seems to be ok now – I think I may have been having some kind of Cache issue…

    On another note, for the Nivo lightbox option – is there anyway to display the image captions above/below the images?

    Thanks for your help and this plugin – it’s bloody fantastic!


    Image captions should be displayed by default – the only condition is to use title atribute in image link like that:

    <a href="..." title="Your image caption"><img ... /></a>

    Joseph Skelley

    Hi Bartosz,

    I’m not sure what you mean by that – where do I make sure that is placed?

    I have made sure each image has a title and caption etc.

    As you see on that example, they all have the captions below them, but not in the lightbox.

    Sorry about my lack of understanding!


    Ok, please try pasting this into functions.php of your theme:

    function df_add_title_attachment_link($link, $id = null) {
    		$id = intval( $id );
    		$_post = get_post( $id );
    		$post_title = esc_attr( $_post->post_title );
    		return str_replace('<a href', '<a title="'. $post_title .'" href', $link);
    	add_filter('wp_get_attachment_link', 'df_add_title_attachment_link', 10, 2);
    Joseph Skelley

    You are a star!

    That seems to have fixed it – thank you so much :)

    Really appreciate it, thank you!

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