WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] WP's built-in gallery opens images, when clicked, on a blank page (4 posts)

  1. MD84
    Member
    Posted 4 years ago #

    Hey,

    I have a question about WordPress' built-in gallery. When creating a gallery and clicking an individual images, these images open on a blank page.

    I am making use of a custom theme (without the single.php file) and I am testing it on a local server (Apache on a Mac). I also have Lightbox Plus installed for overlaying WordPress to display images.

    For Lightbox Plus:
    I checked the 'Use For WP Gallery' checkbox and using '[gallery link="file" order="DESC" columns="4"]' as my short code.

    With or without the Lightbox Plus plugin the actual gallery does work, only the images, when clicked, open on a blank page.

    I do not know what the problem is and how I can fix it. Anybody?

  2. MD84
    Member
    Posted 4 years ago #

    Can somebody please help me?

    (Also duplicating the page.php and turning it into the single.php does not the trick for me. So I'm still stuck.)

  3. MD84
    Member
    Posted 4 years ago #

    I am still having problems with this, can somebody help me please...

  4. MD84
    Member
    Posted 4 years ago #

    I found the solution!

    - As a plugin I used 'Lightbox-2' (it also worked with 'Lightbox Plus').
    - When adding an image make sure that the image's hyperlink is linked to the file itself instead of the post.
    - Make sure that <?php wp_head(); ?> is added to your header.php file (for the specific location look at the default theme).
    - Make sure that <?php wp_footer(); ?> is added to your footer.php file (for the specific location look at the default theme).
    - Sometimes it is necessary to select certain options within the plugin itself.

    This worked for me, yes!

Topic Closed

This topic has been closed to new replies.

About this Topic