RE: [PHP] Client side fatal PHP error

From: Date: Tue, 25 Dec 2001 19:35:43 +0000
Subject: RE: [PHP] Client side fatal PHP error
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-78728@lists.php.net to get a copy of this message
Well, what you have said here isn't that clear, however consider the following revised code: $teststr = strtoupper(substr($xmbrcode,11,1)); if(($teststr != "B") && ($teststr != "P") && ($teststr != "H") && ($teststr != "O")){ do.. } What you are doing is executing the substr and strtoupper many times, which, on a slow connection which may have backlog (thus slower time for the html stream buffer to be delivered), it could timeout. More detail on a: the error, and b: the code *in context* would help. Regards, James Cox > -----Original Message----- > From: jjt [mailto:jjt3d@aol.com] > Sent: Tuesday, December 25, 2001 6:36 PM > To: php-general@lists.php.net > Subject: [PHP] Client side fatal PHP error > > > A visitor to my site repeatedly receives a fatal error in one of > my scripts. > > He is using a Compaq PC with IE 6; Windows 98. He gets this error message: > "Call to unsupported or undefined function srtoupper() in.... on line 82." > > Line 82 is a compound IF statement which uses strtoupper(). As best I can > tell, the syntax of the statement is fine: > > if (strtoupper(substr($xmbrcode,11,1)) != "B" && > strtoupper(substr($xmbrcode,11,1)) != "P" && > srtoupper(substr($xmbrcode,11,1)) != "H" && > srtoupper(substr($xmbrcode,11,1)) != "O").... { > > And more significantly, no one else is reporting this error; I cannot > reproduce it. The script is executed thousands of times each day. By the > time he gets to line 82, he has successfully passed another simple > strtoupper() statement. Every user running this script must get past line > 82. > > I am very confused here. Why does this error occur only on his computer? > How could it be machine or browser dependent? Isn't all PHP processing > done on my host (server) computer? And if so, why does the error not > occur every time the script is executed? > > I am totally baffled by this. Can anyone help? > > Thanks, > > Hershel M. Chicowitz > hchicowitz@aol.com > > > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#78728) next »