<?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>Element Design &#187; PHP</title>
	<atom:link href="http://elementdesignllc.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://elementdesignllc.com</link>
	<description></description>
	<lastBuildDate>Fri, 11 Jun 2010 13:37:49 +0000</lastBuildDate>
	
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Simple PHP Random Image Script</title>
		<link>http://elementdesignllc.com/2010/03/php-random-image-script/</link>
		<comments>http://elementdesignllc.com/2010/03/php-random-image-script/#comments</comments>
		<pubDate>Tue, 16 Mar 2010 13:00:16 +0000</pubDate>
		<dc:creator>chad</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[rand()]]></category>
		<category><![CDATA[random image]]></category>

		<guid isPermaLink="false">http://elementdesignllc.com/?p=518</guid>
		<description><![CDATA[There are times when working with smaller sites you need a simple method of displaying random images. This can be done in one line of text directly in your HTML and a collection of images.
Prepare the Images
The first step is to gather together the images you wish to have randomly rotated. Change all of their [...]]]></description>
			<content:encoded><![CDATA[<p>There are times when working with smaller sites you need a simple method of displaying random images. This can be done in one line of text directly in your HTML and a collection of images.</p>
<h2>Prepare the Images</h2>
<p>The first step is to gather together the images you wish to have randomly rotated. Change all of their file names to a numerical order, starting with the number 1.</p>
<ul>
<li>1.jpg</li>
<li>2.jpg</li>
<li>3.jpg</li>
<li>4.jpg</li>
</ul>
<p>Be sure each image has the same extension (either all jpg, png, or gif), and that there are no gaps in the numbers. Also, place these images in their own folder to keep everything organized.</p>
<h2>Write the Code</h2>
<p>Now in the HTML of your page, insert the following code where you want an image to display:</p>
<pre class="brush: php;">
&lt;img src=&quot;/path/to/&lt;?php echo rand(1,n);?&gt;.jpg&quot; alt=&quot;Random Image&quot; /&gt;
</pre>
<p>The &#8220;rand&#8221; operator will display a randomly generated number between 1 and &#8216;n&#8217;. Change &#8216;n&#8217; to the total amount of pictures you have arranged numerically (or the highest numbered picture you have). In the example above I only have 4 pictures, therefor I would change it to: rand(1,4);</p>
<p>To finish it off, change &#8216;/path/to/&#8217; to the path your stored the images in.</p>
]]></content:encoded>
			<wfw:commentRss>http://elementdesignllc.com/2010/03/php-random-image-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP 5.3 and MySQLi Prepared Statements</title>
		<link>http://elementdesignllc.com/2009/11/php-5-3-and-mysqli-prepared-statements/</link>
		<comments>http://elementdesignllc.com/2009/11/php-5-3-and-mysqli-prepared-statements/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 16:06:02 +0000</pubDate>
		<dc:creator>chad</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[mysqli]]></category>
		<category><![CDATA[prepared statements]]></category>

		<guid isPermaLink="false">http://elementdesignllc.com/?p=409</guid>
		<description><![CDATA[There seems to be an issue with PHP 5.3 and MySQLi Prepared Statements. The procedural code I wrote works fine in 5.2.x, but once I upgraded to 5.3, the results were bizzare. It would pull about 20-50 characters from the field, duplicate the last several characters over and over again (in and around the div [...]]]></description>
			<content:encoded><![CDATA[<p>There seems to be an issue with PHP 5.3 and MySQLi Prepared Statements. The procedural code I wrote works fine in 5.2.x, but once I upgraded to 5.3, the results were bizzare. It would pull about 20-50 characters from the field, duplicate the last several characters over and over again (in and around the div container I had set for it), and even change some of the HTML code that was supposed to be outputted onto the page.</p>
<p>So if you are using prepared statements, I recommend staying away from 5.3 until they get everything ironed out.</p>
]]></content:encoded>
			<wfw:commentRss>http://elementdesignllc.com/2009/11/php-5-3-and-mysqli-prepared-statements/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP APC for Windows Download</title>
		<link>http://elementdesignllc.com/2009/08/php-apc-for-windows-download/</link>
		<comments>http://elementdesignllc.com/2009/08/php-apc-for-windows-download/#comments</comments>
		<pubDate>Wed, 19 Aug 2009 15:46:55 +0000</pubDate>
		<dc:creator>chad</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[apc]]></category>
		<category><![CDATA[extension]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://elementdesignllc.com/?p=259</guid>
		<description><![CDATA[PECL 4 Win has been down for quite a while making the search for some PHP extensions unnecessarily difficult. I&#8217;m offering this permanent APC download for not only my records, but to help others searching for it. As of August 19th, 2009, 3.1.3 is the latest beta version, and 3.0.19 is the latest stable.
Download php_apc [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://pecl4win.php.net/" target="_blank">PECL 4 Win</a> has been down for quite a while making the search for some PHP extensions unnecessarily difficult. I&#8217;m offering this permanent APC download for not only my records, but to help others searching for it. As of August 19th, 2009, 3.1.3 is the latest beta version, and 3.0.19 is the latest stable.</p>
<p><a href="http://elementdesignllc.com/wp-content/uploads/php_apc_3_0_19.dll">Download php_apc (Windows 3.0.19 Stable)</a></p>
<p><a href="http://elementdesignllc.com/wp-content/uploads/php_apc_3_1_3.dll">Download php_apc (Windows 3.1.3 Beta)</a></p>
<p>For more information on APC, please visit the <a href="http://pecl.php.net/package/APC" target="_blank">PECL page</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://elementdesignllc.com/2009/08/php-apc-for-windows-download/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
	</channel>
</rss>
