RE: [PHP-DB] Warning message -- session side-effect
I just came across this yesterday in fact. If you look in your php.ini file, you will see the following ; PHP 4.2 and less have an undocumented feature/bug that allows you to ; to initialize a session variable in the global scope, albeit register_globals ; is disabled. PHP 4.3 and later will warn you, if this feature is used. ; You can disable the feature and the warning seperately. At this time, ; the warning is only displayed, if bug_compat_42 is enabled. session.bug_compat_42 = 0 //yours is likely set to 1 session.bug_compat_warn = 1 Hope this helps. -Original Message- From: Matt M. [mailto:[EMAIL PROTECTED] Sent: Friday, August 27, 2004 5:43 AM To: Worrawut Poonsuk Cc: PHP DB List Subject: Re: [PHP-DB] Warning message -- session side-effect > Warning: Unknown(): Your script possibly relies on a session > side-effect which existed until PHP 4.2.3. Please be advised that the > session extension does not consider global variables as a source of > data, unless register_globals is enabled. You can disable this > functionality and this warning by setting > session.bug_compat_42 or session.bug_compat_warn to off, respectively. > in Unknown on line 0 you have any code examples. Try looking into using the $_SESSION array. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Warning message -- session side-effect
> Warning: Unknown(): Your script possibly relies on a session side-effect which > existed until PHP 4.2.3. Please be advised that the session extension does > not consider global variables as a source of data, unless register_globals > is enabled. You can disable this functionality and this warning by setting > session.bug_compat_42 or session.bug_compat_warn to off, respectively. in Unknown on > line 0 you have any code examples. Try looking into using the $_SESSION array. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Warning message
Logging them may work better. Thank you -Original Message- From: Pierre-Alain Joye [mailto:paj@;pearfr.org] Sent: Thursday, November 07, 2002 1:41 PM To: Anderson, Jerrad Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Warning message On Thu, 7 Nov 2002 13:37:49 -0500 "Anderson, Jerrad" <[EMAIL PROTECTED]> wrote: > I'm using PHP on apache that's sitting on a Windows 2k server. When I > don't define a variable i'm getting a warning message on the screen.. > anyway to suppress these errors? > > > Warning: Undefined variable: yaddayaddaydaadda You may better to fix all warnings/errors instead of hiding them :-) Changes the error reporting level (see error_reporting() in the manual). Nota Bene: If you need to hide php messages in your production environment, you may disable output messages in php.ini, and log them. hth pa -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Warning message
On Thu, 7 Nov 2002 13:37:49 -0500 "Anderson, Jerrad" <[EMAIL PROTECTED]> wrote: > I'm using PHP on apache that's sitting on a Windows 2k server. When I > don't define a variable i'm getting a warning message on the screen.. > anyway to suppress these errors? > > > Warning: Undefined variable: yaddayaddaydaadda You may better to fix all warnings/errors instead of hiding them :-) Changes the error reporting level (see error_reporting() in the manual). Nota Bene: If you need to hide php messages in your production environment, you may disable output messages in php.ini, and log them. hth pa -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Warning message
I'm using PHP on apache that's sitting on a Windows 2k server. When I don't define a variable i'm getting a warning message on the screen.. anyway to suppress these errors? Warning: Undefined variable: yaddayaddaydaadda thanks for any info jerrad -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php