Bug #77608 [Com]: http_build_query doesn't encode "+" in a float number

From: Date: Tue, 12 Feb 2019 10:10:25 +0000
Subject: Bug #77608 [Com]: http_build_query doesn't encode "+" in a float number
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-219525@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=77608&edit=1 ID: 77608 Comment by: wxiaoguang at gmail dot com Reported by: wxiaoguang at gmail dot com Summary: http_build_query doesn't encode "+" in a float number Status: Closed Type: Bug Package: *URL Functions PHP Version: 7.2.15 Assigned To: nikic Block user comment: N Private report: N New Comment: I think this bug also affects other (all) php versions. Will all verions of PHP get this bug fix? Previous Comments: ------------------------------------------------------------------------ [2019-02-12 09:51:07] nikic@php.net Automatic comment on behalf of nikita.ppv@gmail.com Revision: http://git.php.net/?p=php-src.git;a=commit;h=8e34de475699a4aa0fbc7b8430574b56dc839362 Log: Fixed bug #77608 ------------------------------------------------------------------------ [2019-02-12 04:48:18] wxiaoguang at gmail dot com Description: ------------ http_build_query doesn't encode "+" in a float number (eg: 1E+14) The "+" should be encoded to "%2B" in the output. Test script: --------------- $a["x"]=1E+14; echo http_build_query($a); Expected result: ---------------- x=1.0E%2B14 Actual result: -------------- x=1.0E+14 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=77608&edit=1

« previous php.bugs (#219525) next »