<?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>undefined-type &#187; random</title>
	<atom:link href="http://undefined-type.com/tag/random/feed/" rel="self" type="application/rss+xml" />
	<link>http://undefined-type.com</link>
	<description>Flex,Flash &#38; AIR</description>
	<lastBuildDate>Wed, 18 Nov 2009 09:48:23 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Blog Header Images</title>
		<link>http://undefined-type.com/2008/08/blog-header-images/</link>
		<comments>http://undefined-type.com/2008/08/blog-header-images/#comments</comments>
		<pubDate>Sun, 03 Aug 2008 17:44:34 +0000</pubDate>
		<dc:creator>Bäcker</dc:creator>
				<category><![CDATA[Life]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[header]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[random]]></category>

		<guid isPermaLink="false">http://localhost/undefined_type_/?p=158</guid>
		<description><![CDATA[Tried to look at AMFPHP and by doing that I need to learn some basics in PHP. So with that I did a little image header swap for my blog. Did 4 small images.
The PHP looks like this.

// Change this to the total number of images in the folder
$total = &#34;4&#34;;
// Change to the type [...]]]></description>
			<content:encoded><![CDATA[<p>Tried to look at AMFPHP and by doing that I need to learn some basics in PHP. So with that I did a little image header swap for my blog. Did 4 small images.<br />

<a href='http://undefined-type.com/2008/08/blog-header-images/header-bg1/' title='header-bg1'><img width="150" height="150" src="http://undefined-type.com/wp-content/uploads/header-bg1-150x150.jpg" class="attachment-thumbnail" alt="" title="header-bg1" /></a>
<a href='http://undefined-type.com/2008/08/blog-header-images/header-bg2/' title='header-bg2'><img width="150" height="150" src="http://undefined-type.com/wp-content/uploads/header-bg2-150x150.jpg" class="attachment-thumbnail" alt="" title="header-bg2" /></a>
<a href='http://undefined-type.com/2008/08/blog-header-images/header-bg3/' title='header-bg3'><img width="150" height="150" src="http://undefined-type.com/wp-content/uploads/header-bg3-150x150.jpg" class="attachment-thumbnail" alt="" title="header-bg3" /></a>
<a href='http://undefined-type.com/2008/08/blog-header-images/header-bg4/' title='header-bg4'><img width="150" height="150" src="http://undefined-type.com/wp-content/uploads/header-bg4-150x150.jpg" class="attachment-thumbnail" alt="" title="header-bg4" /></a>
</p>
<p>The PHP looks like this.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">// Change this to the total number of images in the folder</span>
<span style="color: #000088;">$total</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;4&quot;</span><span style="color: #339933;">;</span>
<span style="color: #666666; font-style: italic;">// Change to the type of files to use eg. .jpg or .gif</span>
<span style="color: #000088;">$file_type</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;.jpg&quot;</span><span style="color: #339933;">;</span>
<span style="color: #666666; font-style: italic;">// Change to the location of the folder containing the images</span>
<span style="color: #000088;">$image_folder</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;images&quot;</span><span style="color: #339933;">;</span>
<span style="color: #666666; font-style: italic;">// You do not need to edit below this line</span>
<span style="color: #000088;">$start</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;1&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$random</span> <span style="color: #339933;">=</span> <span style="color: #990000;">mt_rand</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$start</span><span style="color: #339933;">,</span> <span style="color: #000088;">$total</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$image_name</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$random</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$file_type</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;&amp;lt;div id=<span style="color: #000099; font-weight: bold;">\&quot;</span>header<span style="color: #000099; font-weight: bold;">\&quot;</span> style=<span style="color: #000099; font-weight: bold;">\&quot;</span>background-image: URL(<span style="color: #006699; font-weight: bold;">$image_folder</span>/header-bg<span style="color: #006699; font-weight: bold;">$image_name</span>);background-repeat:no-repeat<span style="color: #000099; font-weight: bold;">\&quot;</span>&amp;gt;&quot;</span><span style="color: #339933;">;</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://undefined-type.com/2008/08/blog-header-images/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

