That's great advice... the only questions i have then: I only need to call session_start ONCE in my entire application per instance of a session? when i published the application months ago to my production server i had errors on every page notifying me that a session had not been started so i could not call $_SESSION...
~pj "Justin French" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Monday, February 2, 2004, at 10:14 AM, Phillip Jackson wrote: > > > these errors are foreign to me as i have combed my code 100's of times > > before i deployed my app online 3 months ago. do i NEED this > > newer,stricter > > version or can i install a deprecated one? > > It's not newer and stricter, and it's not Apache -- it's PHP error > notices set to a higher level that your production server. > > This is really around the wrong way -- your local (dev) server should > be set to a high level of warning (mine's set to the highest) to > encourage good programming practices, and should be set to none on the > production (live) server to keep error messages out of the user > experience. > > The long answer is to fix your application, and hunt down all these > notices/warnings, so that your application is of better quality. > > The short answer is to set the error reporting on the live server to a > lower level, so that these messages are suppressed. You can do this > either with ini_set()[1] or error_reporting()[2] at the top of every > script (or in a header include for example), or at an application level > with a .htaccess file in root directory. > > A sample of a .htaccess file would be: > > <IfModule mod_php4.c> > php_flag register_globals off > php_flag magic_quotes_runtime off > php_flag magic_quotes_gpc on > php_value url_rewriter.tags 'a=href' > php_value error_reporting 'E_ALL & ~E_NOTICE' > </IfModule> > > I'm not 100% sure the last line is correct, because I'v always done it > with ini_set() in my PHP application. > [1] http://www.php.net/ini_set > [2] http://www.php.net/error-reporting > > > I would encourage you to fix your code as well as apply error reporting > levels for both the production and live servers. > > > Good luck, > > Justin French -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php