Re: why is '01' == '1.'?

From: Date: Thu, 15 Dec 2005 15:11:41 +0000
Subject: Re: why is '01' == '1.'?
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-21234@lists.php.net to get a copy of this message
> Don't forget that one fundamental aspect of PHP is, that it's a web > language and thus receives most of its input from the web. > Therefore it usually only gets strings as input. > > Consider ($_POST['intfield1'] == $_POST['intfield2']) > > Both variables would be strings. Still if someone would input '01' > and '1.' you'd want this expression to return true. > However, XForms will have numeric datatypes. :| http://www.w3.org/TR/2003/REC-xforms-20031014/slice5.html Bart

« previous php.internals (#21234) next »