Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thanks so much for this thread, took away a good four hours of my time as well. I eventually did exactly what OP did, copying and renaming the function. LOL at the second post… I didn’t even see that! XD

    Thread Starter jparge

    (@jparge)

    So it took a while but I figured it out.

    If anybody wants to have the same effect, you can do so by taking a look at the following file: root/wp-content/plugins/nextgen-gallery/view/gallery.php

    And what you are looking for is the following section:

    <!-- Thumbnails -->
    	<?php foreach ($images as $image) : ?>
    
    	<div id="ngg-image-<?php echo $image->pid ?>" class="ngg-gallery-thumbnail-box" <?php echo $gallery->imagewidth ?> >
    		<div class="ngg-gallery-thumbnail" >
    			<a href="<?php echo $image->imageURL ?>" title="<?php echo $image->description ?>" <?php echo $image->thumbcode ?> >
    				<img title="<?php echo $image->alttext ?>" alt="<?php echo $image->alttext ?>" src="<?php echo $image->thumbnailURL ?>" <?php echo $image->size ?> />
    			</a>
    		</div>
    	</div>
    	<?php if ( $gallery->columns > 0 &amp;&amp; ++$i % $gallery->columns == 0 ) { ?>
    	<br style="clear: both" />
    	<?php } ?>
     	<?php endforeach; ?>

    If you want the image title above the description text in the thickbox, you need to make the following alteration:

    <!-- Thumbnails -->
    	<?php foreach ($images as $image) : ?>
    
    	<div id="ngg-image-<?php echo $image->pid ?>" class="ngg-gallery-thumbnail-box" <?php echo $gallery->imagewidth ?> >
    		<div class="ngg-gallery-thumbnail" >
    			<a href="<?php echo $image->imageURL ?>" title="<strong><?php echo $image->alttext ?></strong><br /><?php echo $image->description ?>" <?php echo $image->thumbcode ?> >
    				<img title="<?php echo $image->alttext ?>" alt="<?php echo $image->alttext ?>" src="<?php echo $image->thumbnailURL ?>" <?php echo $image->size ?> />
    			</a>
    		</div>
    	</div>
    	<?php if ( $gallery->columns > 0 &amp;&amp; ++$i % $gallery->columns == 0 ) { ?>
    	<br style="clear: both" />
    	<?php } ?>
     	<?php endforeach; ?>

    The code added was this:
    <strong><?php echo $image->alttext ?></strong><br />

    and it was added to this:
    <a href="<?php echo $image->imageURL ?>" title="<?php echo $image->description ?>

    I hope that clears it up for anyone who was interested in this.

    You can change strong to whatever you want, I’m using <H6> which I’ve customized in the style sheet – works perfectly. All the best!

Viewing 2 replies - 1 through 2 (of 2 total)