<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Dynamically Display Images From a Directory</title>
	<atom:link href="http://normansheppard.com/dynamically-display-images-from-a-directory/feed/" rel="self" type="application/rss+xml" />
	<link>http://normansheppard.com/dynamically-display-images-from-a-directory/</link>
	<description></description>
	<lastBuildDate>Thu, 02 Sep 2010 10:46:50 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
	<item>
		<title>By: Norman Sheppard</title>
		<link>http://normansheppard.com/dynamically-display-images-from-a-directory/comment-page-1/#comment-494</link>
		<dc:creator>Norman Sheppard</dc:creator>
		<pubDate>Thu, 09 Jul 2009 17:51:39 +0000</pubDate>
		<guid isPermaLink="false">http://normansheppard.com/?p=29#comment-494</guid>
		<description>There is no error trapping in this script so it could be several things.
 
Are there actually .gif files in the directory you are reading?

is $dir set to a relative path with a / at the end?

What version of php is running?

Try adding the following in under the $image=&quot;&quot;;

if (!$dir) {echo &#039;ERROR: No directory.&#039;; exit;}	

if (!$dirHandle) {echo &#039;ERROR: Unable to open the directory.&#039;; exit;}	

Try replacing the sort($image); with this
      if ($image == NULL) {
         print(&quot;Sorry, GIF files here&quot;);
      } else {
          sort($image); 
      }</description>
		<content:encoded><![CDATA[<p>There is no error trapping in this script so it could be several things.</p>
<p>Are there actually .gif files in the directory you are reading?</p>
<p>is $dir set to a relative path with a / at the end?</p>
<p>What version of php is running?</p>
<p>Try adding the following in under the $image=&#8221;";</p>
<p>if (!$dir) {echo &#8216;ERROR: No directory.&#8217;; exit;}	</p>
<p>if (!$dirHandle) {echo &#8216;ERROR: Unable to open the directory.&#8217;; exit;}	</p>
<p>Try replacing the sort($image); with this<br />
      if ($image == NULL) {<br />
         print(&#8220;Sorry, GIF files here&#8221;);<br />
      } else {<br />
          sort($image);<br />
      }</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ik</title>
		<link>http://normansheppard.com/dynamically-display-images-from-a-directory/comment-page-1/#comment-492</link>
		<dc:creator>ik</dc:creator>
		<pubDate>Thu, 09 Jul 2009 13:48:42 +0000</pubDate>
		<guid isPermaLink="false">http://normansheppard.com/?p=29#comment-492</guid>
		<description>Hi Norman,
Tried to use your code, but i&#039;m getting these error lines:
Warning: sort() expects parameter 1 to be array, string given in /home/virtual/studiopa/public_html/preview/rooms_01.php on line 26

Fatal error: Cannot use string offset as an array in /home/virtual/studiopa/public_html/preview/rooms_01.php on line 37
What should i do?</description>
		<content:encoded><![CDATA[<p>Hi Norman,<br />
Tried to use your code, but i&#8217;m getting these error lines:<br />
Warning: sort() expects parameter 1 to be array, string given in /home/virtual/studiopa/public_html/preview/rooms_01.php on line 26</p>
<p>Fatal error: Cannot use string offset as an array in /home/virtual/studiopa/public_html/preview/rooms_01.php on line 37<br />
What should i do?</p>
]]></content:encoded>
	</item>
</channel>
</rss>
