<?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/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>zaru blog &#187; CakePHP</title>
	<atom:link href="http://zaru.tofu-kun.org/category/%e3%83%97%e3%83%ad%e3%82%b0%e3%83%a9%e3%83%9f%e3%83%b3%e3%82%b0_php/cakephp/feed/" rel="self" type="application/rss+xml" />
	<link>http://zaru.tofu-kun.org</link>
	<description>Web系のこととかー。</description>
	<lastBuildDate>Tue, 11 May 2010 01:57:44 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://zaru.tofu-kun.org/category/%e3%83%97%e3%83%ad%e3%82%b0%e3%83%a9%e3%83%9f%e3%83%b3%e3%82%b0_php/cakephp/feed/" />
		<item>
		<title>CakePHPをPHP5.3で使うとエラーになる時の対処法</title>
		<link>http://zaru.tofu-kun.org/2010/03/10/cakephp%e3%82%92php5-3%e3%81%a7%e4%bd%bf%e3%81%86%e3%81%a8%e3%82%a8%e3%83%a9%e3%83%bc%e3%81%ab%e3%81%aa%e3%82%8b%e6%99%82%e3%81%ae%e5%af%be%e5%87%a6%e6%b3%95/</link>
		<comments>http://zaru.tofu-kun.org/2010/03/10/cakephp%e3%82%92php5-3%e3%81%a7%e4%bd%bf%e3%81%86%e3%81%a8%e3%82%a8%e3%83%a9%e3%83%bc%e3%81%ab%e3%81%aa%e3%82%8b%e6%99%82%e3%81%ae%e5%af%be%e5%87%a6%e6%b3%95/#comments</comments>
		<pubDate>Wed, 10 Mar 2010 09:03:02 +0000</pubDate>
		<dc:creator>zaru</dc:creator>
				<category><![CDATA[CakePHP]]></category>
		<category><![CDATA[プログラミング_PHP]]></category>

		<guid isPermaLink="false">http://zaru.tofu-kun.org/?p=154</guid>
		<description><![CDATA[PHP5.3だとエラーが色々と…
PHP5.1からPHP5.3へアップデートをすると、CakePHP1.2においてエラーが出てしまったので、その場合の対処法。
Deprecatedエラーが出る
Deprecated: Assigning the return value of new by reference is deprecated in云々なエラー。

cake/libs/configure.php (295行目付近）


if (isset($config['debug'])) {
	if ($_this-&#62;debug) {
		error_reporting(E_ALL);
		//下記追加
		if (error_reporting() &#62; 6143) {
			error_reporting(E_ALL &#38; ~E_DEPRECATED);
		}
		//ここまで

strtotime()でタイムゾーンのエラーが出る
Warning: strtotime() [http://php.net/function.strtotime]: It is not safe to rely on the system’s timezone settings.というエラー。

/etc/php.ini


[Date]
; Defines the default timezone used by the date functions
;date.timezone =
date.timezone =Asia/Tokyo

と、タイムゾーンを設定してやれば大丈夫。
]]></description>
			<content:encoded><![CDATA[<h3>PHP5.3だとエラーが色々と…</h3>
<p>PHP5.1からPHP5.3へアップデートをすると、CakePHP1.2においてエラーが出てしまったので、その場合の対処法。</p>
<h3>Deprecatedエラーが出る</h3>
<p>Deprecated: Assigning the return value of new by reference is deprecated in云々なエラー。</p>
<ul>
<li>cake/libs/configure.php (295行目付近）</li>
</ul>
<pre class="brush: php;">
if (isset($config['debug'])) {
	if ($_this-&gt;debug) {
		error_reporting(E_ALL);
		//下記追加
		if (error_reporting() &gt; 6143) {
			error_reporting(E_ALL &amp; ~E_DEPRECATED);
		}
		//ここまで
</pre>
<h3>strtotime()でタイムゾーンのエラーが出る</h3>
<p>Warning: strtotime() [http://php.net/function.strtotime]: It is not safe to rely on the system’s timezone settings.というエラー。</p>
<ul>
<li>/etc/php.ini</li>
</ul>
<pre class="brush: bash;">
[Date]
; Defines the default timezone used by the date functions
;date.timezone =
date.timezone =Asia/Tokyo
</pre>
<p>と、タイムゾーンを設定してやれば大丈夫。</p>
<img src="http://zaru.tofu-kun.org/?ak_action=api_record_view&id=154&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://zaru.tofu-kun.org/2010/03/10/cakephp%e3%82%92php5-3%e3%81%a7%e4%bd%bf%e3%81%86%e3%81%a8%e3%82%a8%e3%83%a9%e3%83%bc%e3%81%ab%e3%81%aa%e3%82%8b%e6%99%82%e3%81%ae%e5%af%be%e5%87%a6%e6%b3%95/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://zaru.tofu-kun.org/2010/03/10/cakephp%e3%82%92php5-3%e3%81%a7%e4%bd%bf%e3%81%86%e3%81%a8%e3%82%a8%e3%83%a9%e3%83%bc%e3%81%ab%e3%81%aa%e3%82%8b%e6%99%82%e3%81%ae%e5%af%be%e5%87%a6%e6%b3%95/" />
	</item>
	</channel>
</rss>
