<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Steve&#039;s Journal &#187; Thumbnails</title>
	<atom:link href="http://www.kf8ki.com/tag/thumbnails/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.kf8ki.com</link>
	<description>Just another day in paradise...</description>
	<lastBuildDate>Sat, 04 Feb 2012 21:41:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Nextgen Gallery Image Navigation</title>
		<link>http://www.kf8ki.com/geek-stuff/nextgen-gallery-image-navigation/</link>
		<comments>http://www.kf8ki.com/geek-stuff/nextgen-gallery-image-navigation/#comments</comments>
		<pubDate>Sun, 28 Dec 2008 19:39:26 +0000</pubDate>
		<dc:creator>Steve</dc:creator>
				<category><![CDATA[Geek Stuff]]></category>
		<category><![CDATA[1.0.2]]></category>
		<category><![CDATA[2.7]]></category>
		<category><![CDATA[Navigation]]></category>
		<category><![CDATA[Nextgen]]></category>
		<category><![CDATA[Thickbox]]></category>
		<category><![CDATA[Thumbnails]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.kf8ki.com/blog/?p=328</guid>
		<description><![CDATA[Hi Everyone! I&#8217;ve decided I&#8217;m going to start adding some other geeky stuff here too.  I&#8217;ve been using WordPress lately as a content management system (CMS) for several of my websites, and all I can say is, I&#8217;m in love!  &#8230; <a href="http://www.kf8ki.com/geek-stuff/nextgen-gallery-image-navigation/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi Everyone!</p>
<p>I&#8217;ve decided I&#8217;m going to start adding some other geeky stuff here too.  I&#8217;ve been using WordPress lately as a content management system (CMS) for several of my websites, and all I can say is, I&#8217;m in love!  I&#8217;ve also found a fabulous plugin for images for WordPress called Nextgen Gallery.  I&#8217;ve been using both through several versions now and am currently on WordPress 2.7 and Nexten Gallery 1.0.2.</p>
<p>In case you&#8217;re interested in WordPress, you can find it<a href="http://wordpress.org/" target="_blank"> here</a>, and Nextgen Gallery is <a href="http://alexrabe.boelinger.com/wordpress-plugins/nextgen-gallery/" target="_blank">here</a>.  Lots of examples at the Nextgen site as well.</p>
<p>One of the small changes I&#8217;d like made in Nextgen Gallery is the way the navigation through images is done if you use pagination.  Currently if you set max images to something other than 0, it limits the number of thumbnails displayed to that number.  I happen to like 4 because it doesn&#8217;t crowd the posts with a million thumbnails.  When you click on a thumbnail, it opens a Thickbox with the image.  The problem is, the Thickbox includes previous and next links to move through the images, but they only navigate through the limited number of images on that page and not the whole gallery.</p>
<p>I want them to navigate through the whole gallery so you don&#8217;t have to switch back and forth and navigate through both the pages AND the images.  Unfortunately this isn&#8217;t a feature that&#8217;s included.  In a previous version of Nextgen, 0.99, I followed some online instructions to modify the plugin to get it to do what I wanted.  If you&#8217;re using that version, you can find those instructions <a href="http://www.liveworkdream.com/2007/12/02/edit-nextgen-gallery-plugin/" target="_blank">here</a>.  Unfortuantely, they don&#8217;t work for the newest version (1.0.2) because of significant changes to the applicable routines.  So&#8230; I got to work.  To make a long story a bit shorter, here are the modification instructions:</p>
<div class="threadpost col-7">
<div class="post">
<p>#1 &#8211; In nggfunctions.php</p>
<p>Find the lines that look like:</p>
<pre><span style="color: #0000ff;"><code>// remove the element if we didn't start at the beginning
if ($start &gt; 0 ) array_splice($picturelist, 0, $start);

// return the list of images we need
array_splice($picturelist, $maxElement);</code></span></pre>
<p>Comment them out or delete them.  Just below where they are (or were) add:</p>
<pre><span style="color: #0000ff;"><code>//Don't modify the array.  We now want to pass all of the picture list
//to the output... but not all are visible as thumbnails.
//TODO:  make a configuration option to select or deselect this
//behavior

foreach ($picturelist as $index =&gt; $value)
{
if (($index &lt; $start) || ($index &gt;= ($start + $maxElement)))
  $picturelist[$index]-&gt;imageHidden = 1;  //if out of range,
                                          //hide image
else
  $picturelist[$index]-&gt;imageHidden = 0;  //otherwise, show it
		}</code></span></pre>
<p>#2 &#8211; in /lib/image.php find the the following about line 18:</p>
<pre><span style="color: #0000ff;"><code>var $href = '';		// A href link code</code></span></pre>
<p>Below it, add:</p>
<pre><span style="color: #0000ff;"><code>var $imageHidden = 0;  	// show or not show thumbnail</code></span></pre>
<p>#3 &#8211; lastly, in /view/gallery.php find these lines, starting about line 37:</p>
<pre><span style="color: #0000ff;"><code>&lt;!-- Thumbnails --&gt;
&lt;?php foreach ($images as $image) : ?&gt;

&lt;div id="ngg-image-&lt;?php echo $image-&gt;pid ?&gt;"
class="ngg-gallery-thumbnail-box"&gt;</code></span></pre>
<p>Delete the &lt;div.. tag.  In it&#8217;s place, paste this:</p>
<pre><span style="color: #0000ff;"><code>&lt;div id="ngg-image-&lt;?php echo $image-&gt;pid ?&gt;"
class="ngg-gallery-thumbnail-box"
&lt;?php
  if ( $image-&gt;imageHidden == 1 )
  {
    echo " style='display: none' ";
  }
?&gt;
&gt;</code></span></pre>
<p>Be careful about the closing bracket on the replacement tag!</p>
<p>That should do it.  It&#8217;s working on this site anyway!  If you want to make the changes but are afraid of doing so, I&#8217;d be happy to email you the necessary files if you say please <img src='http://www.kf8ki.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>You can also follow the discussion on this subject on the WordPress forums <a href="http://wordpress.org/support/topic/228743" target="_blank">here</a>.   Enjoy!</p>
<p>Update 12/29 &#8211; another WordPress user reports the mod is working fine with Lightbox as well.</p>
<p>Steve</p></div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.kf8ki.com/geek-stuff/nextgen-gallery-image-navigation/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

