<?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>「隨機更換WordPress預設佈景主題的Header Image」的迴響</title>
	<atom:link href="http://vicjuan.org/archives/2007/05/06/422/feed" rel="self" type="application/rss+xml" />
	<link>http://vicjuan.org/archives/2007/05/06/422</link>
	<description>我們已經結婚了，嚇到你了啊？真是不好意思啊。</description>
	<lastBuildDate>Thu, 01 Dec 2011 04:00:00 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>由：Wordpress佈景主題產生器專家</title>
		<link>http://vicjuan.org/archives/2007/05/06/422/comment-page-1#comment-2764</link>
		<dc:creator>Wordpress佈景主題產生器專家</dc:creator>
		<pubDate>Sat, 04 Sep 2010 10:22:20 +0000</pubDate>
		<guid isPermaLink="false">http://vicjuan.org/archives/2007/05/06/422#comment-2764</guid>
		<description>最近發現國外有一套針對Wordpress的佈景主題產生器，還不錯用，我有寫網站做專門的介紹。 網址:http://www.diycmstheme.com</description>
		<content:encoded><![CDATA[Mozilla Firefox 3.6.8   Windows 7<p>
最近發現國外有一套針對Wordpress的佈景主題產生器，還不錯用，我有寫網站做專門的介紹。 網址:<a href="http://www.diycmstheme.com" rel="nofollow">http://www.diycmstheme.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>由：vicjuan</title>
		<link>http://vicjuan.org/archives/2007/05/06/422/comment-page-1#comment-39</link>
		<dc:creator>vicjuan</dc:creator>
		<pubDate>Mon, 21 May 2007 02:03:12 +0000</pubDate>
		<guid isPermaLink="false">http://vicjuan.org/archives/2007/05/06/422#comment-39</guid>
		<description>學長真威啊 XD</description>
		<content:encoded><![CDATA[Mozilla Firefox 2.0.0.3   Linux<p>
學長真威啊 XD</p>
]]></content:encoded>
	</item>
	<item>
		<title>由：Drake</title>
		<link>http://vicjuan.org/archives/2007/05/06/422/comment-page-1#comment-38</link>
		<dc:creator>Drake</dc:creator>
		<pubDate>Mon, 21 May 2007 01:53:00 +0000</pubDate>
		<guid isPermaLink="false">http://vicjuan.org/archives/2007/05/06/422#comment-38</guid>
		<description>我之前有用過「寫一個 php function」的方式來做到類似的效果。
在 html 方面，可能會有類似 
然後在那個 ooxx.php 裏頭，程式碼約略如下：
--------------
function _make_seed()
{
    list($usec, $sec) = explode(&#039; &#039;, microtime());
    return (float) $sec   ((float) $usec * 100000);
}

function _banner()
{
    $root = getcwd() . &#039;/files/banner&#039;;
    $front = &#039;&#039;;
    $files = array();
    if( $rhandle = opendir( $root ) ) {
        while( false !== ($dir = readdir( $rhandle )) ) {
            if( $dir == &quot;.&quot; &#124;&#124; $dir == &quot;..&quot; ) continue;
            $file = $dir;
            if( !is_file( &quot;$root/$file&quot; ) ) continue;
            $files[] = $file;
        }
        closedir( $rhandle );

        $number = count( $files );
        if( !$number )
            return &#039;&#039;;
        srand(_make_seed());
        $randval = rand();
        $index = $randval % $number;
        $front = $files[$index];
    }
    return $front;
}
echo _banner();
----------------------------------</description>
		<content:encoded><![CDATA[Mozilla Firefox 1.5.0.11   Ubuntu Linux<p>
我之前有用過「寫一個 php function」的方式來做到類似的效果。<br />
在 html 方面，可能會有類似<br />
然後在那個 ooxx.php 裏頭，程式碼約略如下：<br />
&#8212;&#8212;&#8212;&#8212;&#8211;<br />
function _make_seed()<br />
{<br />
    list($usec, $sec) = explode(&#8216; &#8216;, microtime());<br />
    return (float) $sec   ((float) $usec * 100000);<br />
}</p>
<p>function _banner()<br />
{<br />
    $root = getcwd() . &#8216;/files/banner&#8217;;<br />
    $front = ";<br />
    $files = array();<br />
    if( $rhandle = opendir( $root ) ) {<br />
        while( false !== ($dir = readdir( $rhandle )) ) {<br />
            if( $dir == "." || $dir == ".." ) continue;<br />
            $file = $dir;<br />
            if( !is_file( "$root/$file" ) ) continue;<br />
            $files[] = $file;<br />
        }<br />
        closedir( $rhandle );</p>
<p>        $number = count( $files );<br />
        if( !$number )<br />
            return ";<br />
        srand(_make_seed());<br />
        $randval = rand();<br />
        $index = $randval % $number;<br />
        $front = $files[$index];<br />
    }<br />
    return $front;<br />
}<br />
echo _banner();<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-</p>
]]></content:encoded>
	</item>
</channel>
</rss>

