Tech Musings

Friday, April 13, 2007

PHP 5 Entropy Build

This one has gotten me more than once so I thought it best to log it here for future reference. If using the Entropy ( build of PHP 5 for Mac OS X, the php.ini file changes locations. I like to set the display_errors = On if I'm running PHP on my test box (recommend turning to Off in production environment) and sometimes will set register_global=Off from Off to On temporarily to test certain applications. Undoubtedly, I will make these adjustments in the old php.ini file and wonder why they're not working like I expect them to, then after an hour of head scratching remember that entropy uses its own php.ini in the new location. For the record, I've heard you can also manage register globals through .htaccess and virtual site config files, too. It's a security risk to have your register globals on and best to rewrite your code using superglobal array variables instead of taking the easy way out and making the change in the php.ini file. Am I right?!??? ;-)

If your php.ini file was located here /private/etc/php.ini

it switches to this location:



Post a Comment

<< Home