WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Custom album view Nextgen (2 posts)

  1. Gosku
    Member
    Posted 1 year ago #

    Hi everyone!

    I would like to create custom album view which will be showing all images of galeries, not only thumbnail.

    I created my custom album view and I have problem with loop when i want to show images.

    What should i do to get image list from gallery in album?

    This is my loop:

    <?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?><?php if (!empty ($galleries)) : ?>
    
    	<ul id="slider">
    	<?php foreach ($galleries as $gallery) : ?>
    	<li>
    		<h3><?php echo $gallery->title ?></h3>
    		<p><?php echo $gallery->galdesc ?></p>
    
    <!-- I want to show here all images from each gallery - something like we use shortcode [nggallery id=X] -->
    
    	</li>
    
     	<?php endforeach; ?>
     	</ul>
    
    <?php endif; ?>
  2. Gosku
    Member
    Posted 1 year ago #

    Ok, I solved my problem.

    Here is the result:

    <?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?><?php if (!empty ($galleries)) : ?>
    
    	<ul id="slider">
    	<?php foreach ($galleries as $gallery) : ?>
    	<li>
    		<h3><?php echo $gallery->title ?></h3>
    		<p><?php echo $gallery->galdesc ?></p>
    
    <strong><? $ngg = new NextGEN_Shortcodes;
    $id_galeri = $gallery->gid;
     echo $ngg->show_gallery( array("id"=>$gallery->gid,"template"=>"projects") ); ?></strong>
    
    	</li>
    
     	<?php endforeach; ?>
     	</ul>
    
    <?php endif; ?>

Topic Closed

This topic has been closed to new replies.

About this Topic