From: madu dot rapa at gmail dot com
Operating system: ALL
PHP version: 5.4.29
Package: *General Issues
Bug Type: Bug
Bug description:String E conversion to numbers.
Description:
------------
<?php
$x='E'; // Assignment of Parameter
if ( $x!='0') // Check if the value is '0' (string)
{
echo "False";
}
else
{
echo "TRUE";
}
?>
Above code returns False while below code returns TRUE for the if
condition with a warning message --> Notice: Use of undefined constant E
- assumed 'E'
<?php
$x='E'; // Assignment of Parameter
if ( $x!=0) // Check if the value is 0 (integer)
{
echo "False";
}
else
{
echo "TRUE";
}
?>
--
Edit bug report at https://bugs.php.net/bug.php?id=67480&edit=1
--