note 71916 added to function.http-build-query
| From: | havelka at valka dot cz | Date: | Fri, 22 Dec 2006 11:37:18 +0000 |
| Subject: | note 71916 added to function.http-build-query | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-120850@lists.php.net to get a copy of this message | ||
I think it doesnt :( when processing array let say from MySQL db, where array is list of rows
(column - value), it generates the first "row" without indexes
(post_subject=xxx&post_detail=yyy) while the other rows are indexed well (
1[post_subject]=xxx&1[post_details]=yyy )
this causes confusion when the array is read back from this string (because the first line, without
index is ignored (put to another variable than rest of the array), also count of this array says n+x
(N = amount of rows in the array, X = amount of columns in the first row) which is wrong. The
correct way should look like
0[post_subject]=xxx&0[post_detail]=yyy
for the first entry and then to continue with the rest
----
Server IP: 66.163.161.117
Probable Submitter: 194.228.23.10 (proxied: unknown)
----
Manual Page -- http://www.php.net/manual/en/function.http-build-query.php
Edit -- https://master.php.net/note/edit/71916
Del: integrated -- https://master.php.net/note/delete/71916/integrated
Del: useless -- https://master.php.net/note/delete/71916/useless
Del: bad code -- https://master.php.net/note/delete/71916/bad+code
Del: spam -- https://master.php.net/note/delete/71916/spam
Del: non-english -- https://master.php.net/note/delete/71916/non-english
Del: in docs -- https://master.php.net/note/delete/71916/in+docs
Del: other reasons-- https://master.php.net/note/delete/71916
Reject -- https://master.php.net/note/reject/71916
Search -- https://master.php.net/manage/user-notes.php