php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #31811 is_numeric() works diffirent in different versions
Submitted: 2005-02-02 13:31 UTC Modified: 2005-02-02 15:40 UTC
From: shagren at ua dot fm Assigned:
Status: Closed Package: Unknown/Other Function
PHP Version: 4.3.10 OS: linux
Private report: No CVE-ID: None
 [2005-02-02 13:31 UTC] shagren at ua dot fm
Description:
------------
In old versions(i try 4.3.2 cgi) and 5.0 is_numeric("-.12") return "1", but in 4.3.10(apache/mod_php) result are false(bool).

Reproduce code:
---------------
<?
echo is_numeric("-.12");
?>

Expected result:
----------------
1


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-02-02 15:40 UTC] shagren at ua dot fm
I try this versions on Windows(mod_php/apache2, CGI/IIS) and Linux(CGI) and all good. is_numeric("-.12") return 1.
 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Mon May 23 18:05:46 2022 UTC