WordPress.org

Ready to get started?Download WordPress

Forums

NextGEN Gallery
Multiple galleries in one post - pagination affects all galleries at once (1 post)

  1. benhunt01
    Member
    Posted 2 years ago #

    Hi, i have more than one NextGen gallery in the sidebar of a post. The first gallery has thumbnails with the built in pagination beneath (previous, page 1 etc, next). If i click a page number or one of the next / prev arrows in the first gallery it also affects the gallery below jumping to the same page as the gallery above. I've tried with and without the page reload / AJAX options in the NextGen options pages but the problem still occurs. The pagination feature seems to add "?nggpage=2" to the end of the URL string in the browsers address bar for each option.

    I'm using the code below to insert the gallery into the sidebar based upon a custom field within the post which allows me to insert the gallery id. Is there any way to fix this so that the gallery navigation only affects the gallery that is being navigated at the time?

    Thanks for any help, Ben.

    // get image gallery
    				if((get_post_meta($post->ID, "gallery_id", true))) {
    				$gallery_id = get_post_meta( $post->ID, 'gallery_id', true); // Get gallery id from custom field data
      if( isset($gallery_id) ){
    	echo "<div class=\"box_small box widget\"><h3 class=\"widgettitle\">Image gallery</h3>";
        echo "<div class=\"post-gallery\">";
        echo nggShowGallery( $gallery_id ); // Display the gallery
        echo "</div></div>";
      }
    				} // end of get image gallery

    http://wordpress.org/extend/plugins/nextgen-gallery/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic