Learning CakePHP

April 1, 2009

Strict Standards: CakePHP Fresh Install

:) . It’s funny how my enthusiasm to refresh my cakephp knowledge turns to be an ‘ordeal’. I am now facing one error to another. After solving the .htaccess (Namely the 500 Internal Server Error) I am faced with yet another unfamiliar error. A number of errors show on my freshly installed cakephp.

strict-standards-error1

 

My first instinct is that I have to change the “debug” setting mode of cakephp in app/config/core.php. However that is not the case. So I relied again to google and it (keyword search in Google: cakephp Strict Standards: Redefining already defined constructor for class Object in) returned a number of results and the first search result gave me an immediate most direct solution.

According to the blog, MAMP, PHP5, CakePHP, and Strict Standards, this is not a cakephp problem and instead a new PHP5 Error Standard (Oh my! another trouble with the new PHP 5) which can be turned off in two ways:

 

  • Changing your php.ini 
  • Or modifying the .htaccess in your root cakephp installation

The first method requires access to the php.ini (which I do not have) so I went on two solution # 2:

Or, in your .htaccess file in your root cake installation, you can add the following line:

php_value error_reporting 6143

And when I did that, I refreshed my page and saw that the error’s gone. (Yipee!!!)

It is also quite interesting to note that the reason why this error exists (still exists) is to maintain back compatibility with older version of PHP (that is PHP4).

More powers to the Open-Source Community and to the people who continually share their knowledge and experiences for people like me who is just starting to learn (really learn).

Cheers! 

Advertisement

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Theme: Shocking Blue Green. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.