• Hi,

    I’ve created a gallery using the NextGEN Gallery plugin and placed some sponsors logos into it.
    I now want to display those logo images in the footer area of my site full sized (not as thumbnails that click through to the full sized versions). I don’t want a slideshow or anything as fancy as that either, just a way to pick up the contents of said gallery and place them in my footer.

    Is it possible to achieve this, possibly by placing some code in the footer.php template file?

    All help gratefully received.

    Tony.

Viewing 5 replies - 1 through 5 (of 5 total)
  • I don’t think NextGEN has any functions you can put into your template files to display its galleries/slideshows/etc. However, you can do the following:

    <?php
    $custom_gallery_content = ‘[gallery=1]’;
    echo apply_filters(‘the_content’, $custom_gallery_content);
    ?>

    Obviously, $custom_gallery_content can be whatever tags you would use within a post/page to display your gallery.

    Hopefully this helps somebody else out.

    Hey,

    I used the code above, and it works perfectly! Just wondering though if it is possibly to have a different gallery on each post? I have put the above code in my sidebar, and would like the gallery to change, depending on the post.

    I thought I may be able to use the get custom fields tag, but not luck!

    Any one got any ideas?

    Yes, you should be able to do something like this:

    <?php
    if(is_post(X)) { echo apply_filters(‘the_content’, ‘[gallery=1]’); }
    if(is_post(X)) { echo apply_filters(‘the_content’, ‘[gallery=2]’); }
    if(is_post(X)) { echo apply_filters(‘the_content’, ‘[gallery=3]’); }
    ?>

    Where X would be different post/page IDs.

    andypotanin, thanks for posting, I was looking for a solution for my sidebar and your code works perfect.

    Hi Andypotanin,

    I have been searching all over the internet on how to embed a slideshow as header. I tried a number of codes and only yours WORKED !. Thanks for the code and if possible, let me know whether I can change the width and height of the above given template code.

    Thanks
    Jimmy

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: NextGEN Gallery] Insert gallery contents into template’ is closed to new replies.