|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2013-11-07 22:05 UTC] llmll at gmx dot de
Description: ------------ --- From manual page: http://www.php.net/pdo.quote --- The PDO::quote messes around with number formats. The documentation does not mention this. It appears, that quote() checks the variable type, and if it detects a float, it will format it according to the locale. This happens EVEN THOUGH you call quote() without second parameter, which tells it to handle the variables as raw string. Test script: --------------- //string $float = '1.55'; echo PDO::quote($float); // returns '1,55' with point replaced to comma Expected result: ---------------- should either leave strings alone or mention in the documentation, that it does what it does. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Fri Jan 02 16:00:01 2026 UTC |
I think the status should be wont-fix because of the statement of 22nd General Conference on Weights and Measures ("the symbol for the decimal marker shall be either the point on the line or the comma on the line."). The description about locale and link for intl's NumberFormatter is also needed for the doc.