#39830 [NEW]: Incorrect (float) variable output after using setlocale
| From: | ipa at beta dot lt | Date: | Thu, 14 Dec 2006 09:58:01 +0000 |
| Subject: | #39830 [NEW]: Incorrect (float) variable output after using setlocale | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-106350@lists.php.net to get a copy of this message | ||
From: ipa at beta dot lt
Operating system: Linux 2.6.10
PHP version: 4.4.4
PHP Bug Type: Variables related
Bug description: Incorrect (float) variable output after using setlocale
Description:
------------
Strange behaviour on float variable output after using setlocale()
function.
Reproduce code:
---------------
<?php
setlocale(LC_NUMERIC, 'lt_LT');
$xxx = 19.48;
echo ($xxx) . "\n"; // Output float from variable
echo (19.48) . "\n"; // Output float directly
?>
Expected result:
----------------
19,48
19,48
Actual result:
--------------
19,48
19.48
--
Edit bug report at http://bugs.php.net/?id=39830&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=39830&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=39830&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=39830&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=39830&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=39830&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=39830&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=39830&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=39830&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=39830&r=support
Expected behavior: http://bugs.php.net/fix.php?id=39830&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=39830&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=39830&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=39830&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=39830&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=39830&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=39830&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=39830&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=39830&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=39830&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=39830&r=mysqlcfg