This is a discussion on Configuration within the PHP Language forums, part of the PHP Programming Forums category; There's obviously a configuration difference between my development server (running Debian) and a production server I use (running Slackware). ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
There's obviously a configuration difference between my development server
(running Debian) and a production server I use (running Slackware). On my development server, no error is produced in the following statement if $a hasn't been initialized: $b = $a; $a simply returns a null string. On the production server, this is an undefined variable error. Likewise the following $a = $_POST['someVar']; Gets no error on development, but does on production if $_POST['someVar'] is undefined. What configuration parameters control this? tia ---Michael |
|
|||
|
Michael Satterwhite wrote:
> > There's obviously a configuration difference between my development server > (running Debian) and a production server I use (running Slackware). On my > development server, no error is produced in the following statement if $a > hasn't been initialized: > > $b = $a; > > $a simply returns a null string. On the production server, this is an > undefined variable error. Likewise the following > > $a = $_POST['someVar']; > > Gets no error on development, but does on production if $_POST['someVar'] > is undefined. > > What configuration parameters control this? The error_reporting directive: http://www.php.net/manual/en/ref.err...rror-reporting It is often recommended that you do the opposite of what you have right now -- set high level of error reporting on the development server and low one on the production server and not move into production environment until errors stop popping up... Cheers, NC |