Display Errors is both On and Off

Display Errors is both On and Off

am 19.03.2007 14:38:33 von Dana Cartwright

I have a website in which PHP errors are displayed, despite having them
configured to not display.

Here is a test file I created to explore this:

echo ini_get( 'display_errors' );
phpInfo();
?>

The ini_get says "On", the phpInfo says "Off" (for display_errors in the PHP
Core section).

PHP 5.0.4

I'm struggling to understand how, at runtime, I get these conflicting
reports. The configuration files all say display_errors is OFF, and phpInfo
agrees, but PHP acts like they are on, and ini_get shows why.

Re: Display Errors is both On and Off

am 19.03.2007 16:12:46 von kimandre

Dana Cartwright wrote:

> I have a website in which PHP errors are displayed, despite having
> them configured to not display.
>
> Here is a test file I created to explore this:
>
> > echo ini_get( 'display_errors' );
> phpInfo();
> ?>
>
> The ini_get says "On", the phpInfo says "Off" (for display_errors in
> the PHP Core section).
>
> PHP 5.0.4
>
> I'm struggling to understand how, at runtime, I get these conflicting
> reports. The configuration files all say display_errors is OFF, and
> phpInfo agrees, but PHP acts like they are on, and ini_get shows why.

In which column does the phpinfo() show the display_errors setting as
"Off"? "Local Value", "Master Value" or both?

--
Kim André Akerø
- kimandre@NOSPAMbetadome.com
(remove NOSPAM to contact me directly)

Re: Display Errors is both On and Off

am 19.03.2007 16:49:22 von Dana Cartwright

> Dana Cartwright wrote:
>
>> I have a website in which PHP errors are displayed, despite having
>> them configured to not display.
>>
>> Here is a test file I created to explore this:
>>
>> >> echo ini_get( 'display_errors' );
>> phpInfo();
>> ?>
>>
>> The ini_get says "On", the phpInfo says "Off" (for display_errors in
>> the PHP Core section).
>>
>> PHP 5.0.4
>>
>> I'm struggling to understand how, at runtime, I get these conflicting
>> reports. The configuration files all say display_errors is OFF, and
>> phpInfo agrees, but PHP acts like they are on, and ini_get shows why.
>
> In which column does the phpinfo() show the display_errors setting as
> "Off"? "Local Value", "Master Value" or both?

Both "local" and "master" say Off.

> --
> Kim André Akerø
> - kimandre@NOSPAMbetadome.com
> (remove NOSPAM to contact me directly)

Re: Display Errors is both On and Off

am 19.03.2007 17:13:38 von Toby A Inkster

Dana Cartwright wrote:

> I have a website in which PHP errors are displayed, despite having them
> configured to not display.

Have you used something like this in an .htaccess file?

php_value display_errors off

?? Boolean flags like display_errors should be set using "php_flag" instead
of "php_value".

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact
Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux

* = I'm getting there!

Re: Display Errors is both On and Off

am 19.03.2007 19:07:41 von Jerry Stuckle

Dana Cartwright wrote:
> I have a website in which PHP errors are displayed, despite having them
> configured to not display.
>
> Here is a test file I created to explore this:
>
> > echo ini_get( 'display_errors' );
> phpInfo();
> ?>
>
> The ini_get says "On", the phpInfo says "Off" (for display_errors in the PHP
> Core section).
>
> PHP 5.0.4
>
> I'm struggling to understand how, at runtime, I get these conflicting
> reports. The configuration files all say display_errors is OFF, and phpInfo
> agrees, but PHP acts like they are on, and ini_get shows why.
>
>

First of all, are you editing the correct php.ini file? (Probably, but
it's always worth checking).

Next - do you have the php.ini file overridden in your .htaccess or
httpd.conf file?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================