<?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: Running dotMobi WordPress Mobile Pack on PHP 4</title>
	<atom:link href="http://cgarvey.ie/blog/archive/2009/11/02/running-dotmobi-wordpress-mobile-pack-on-php-4/feed/" rel="self" type="application/rss+xml" />
	<link>http://cgarvey.ie/blog/archive/2009/11/02/running-dotmobi-wordpress-mobile-pack-on-php-4/</link>
	<description>The personal blog of Irish mobile and web application developer, Cathal Garvey</description>
	<lastBuildDate>Tue, 31 Jan 2012 19:33:55 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Claudiu</title>
		<link>http://cgarvey.ie/blog/archive/2009/11/02/running-dotmobi-wordpress-mobile-pack-on-php-4/comment-page-1/#comment-2493</link>
		<dc:creator>Claudiu</dc:creator>
		<pubDate>Fri, 10 Sep 2010 12:33:25 +0000</pubDate>
		<guid isPermaLink="false">http://cgarvey.ie/blog/?p=331#comment-2493</guid>
		<description>Or, you could just add a snippet of code in the config file:

&lt;code&gt;if (!function_exists(&#039;file_put_contents&#039;)) {
    function file_put_contents($filename, $data) {
        $f = @fopen($filename, &#039;w&#039;);
        if (!$f) {
            return false;
        } else {
            $bytes = fwrite($f, $data);
            fclose($f);
            return $bytes;
        }
    }
}
&lt;/code&gt;
Just to make sure that you keep compatibility in case you get some updates/add-ons whatever that could insert a file_put_contents somewhere in the code. The same goes for any other PHP5 only function (most can be replicated in PHP4 as well)</description>
		<content:encoded><![CDATA[<p>Or, you could just add a snippet of code in the config file:</p>
<p><code>if (!function_exists('file_put_contents')) {<br />
    function file_put_contents($filename, $data) {<br />
        $f = @fopen($filename, 'w');<br />
        if (!$f) {<br />
            return false;<br />
        } else {<br />
            $bytes = fwrite($f, $data);<br />
            fclose($f);<br />
            return $bytes;<br />
        }<br />
    }<br />
}<br />
</code><br />
Just to make sure that you keep compatibility in case you get some updates/add-ons whatever that could insert a file_put_contents somewhere in the code. The same goes for any other PHP5 only function (most can be replicated in PHP4 as well)</p>
]]></content:encoded>
	</item>
</channel>
</rss>

