php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #52638 Misleading parameter name for http_build_query
Submitted: 2010-08-18 22:31 UTC Modified: 2010-08-19 11:31 UTC
From: marcus at deglos dot com Assigned: rquadling (profile)
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS: n/a
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: marcus at deglos dot com
New email:
PHP Version: OS:

 

 [2010-08-18 22:31 UTC] marcus at deglos dot com
Description:
------------
The documentation for 'http_build_query' ( http://php.net/manual/en/function.http-build-query.php ) lists the first parameter as '$formdata'.

Most uses of http_build_query don't involve forms or formdata, which makes the parameter-name misleading.  People scanning the documentation may ignore this function, thinking that it only applies to forms (I know I've skipped past it many a time!)

Renaming the parameter '$paramaters' or '$query_params' will help users understand the use of this function.


Test script:
---------------
n/a

Expected result:
----------------
n/a

Actual result:
--------------
n/a

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-08-19 11:25 UTC] rquadling@php.net
-Assigned To: +Assigned To: rquadling
 [2010-08-19 11:28 UTC] rquadling@php.net
Automatic comment from SVN on behalf of rquadling
Revision: http://svn.php.net/viewvc/?view=revision&revision=302467
Log: Changed the data paramater from $formdata to $query_data
Documented that only public properties are accessed.
Updated example to show nested objects.
Fix bug#52638
 [2010-08-19 11:31 UTC] rquadling@php.net
-Status: Assigned +Status: Closed
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Thu Oct 08 07:00:01 2026 UTC