On Tue, 20 Nov 2001 13:12, Fred wrote: > OK, it seems as though I was on the right track. I cast the variables > as integers and all is well. Thanks to Rasmus and his msg: > http://www.phpbuilder.com/mail/php-developer-list/199901/0485.php > > A question remains: why are variables that are initially set to numbers > not cast as integers? > > According to the manual variables are initially cast as integers if > they are created with an assignment to an integer number. While this > is the case with variables assigned in code (i.e. $One = 16) it appears > not to be the case with GET variables passed via the URL.
Anything coming via get/post is a string, regardless of what it looks like :-). -- David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA "This is the Netherlands," Tom stated flatly. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]