#23379 [NEW]: comparing "08" and "09" with 08 and 09 returns false

From: Date: Mon, 28 Apr 2003 09:09:08 +0000
Subject: #23379 [NEW]: comparing "08" and "09" with 08 and 09 returns false
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-38532@lists.php.net to get a copy of this message
From: oli dot brouckaert at i-services dot be Operating system: Windows XP PHP version: 4.3.0 PHP Bug Type: Strings related Bug description: comparing "08" and "09" with 08 and 09 returns false Hello I've found a strange bug : <?php $string="01"; // and "02", "03", ... except "08" and "09" echo ($string == 01)?1:0; // shows 1 $string="08"; // also for "09" but not other numbers echo ($string == 08)?1:0; // shows 0 ?> Olivier -- Edit bug report at http://bugs.php.net/?id=23379&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=23379&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=23379&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=23379&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=23379&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=23379&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=23379&r=support Expected behavior: http://bugs.php.net/fix.php?id=23379&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=23379&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=23379&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=23379&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=23379&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=23379&r=dst IIS Stability: http://bugs.php.net/fix.php?id=23379&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=23379&r=gnused

« previous php.bugs (#38532) next »