php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #6997 parse_str
Submitted: 2000-10-03 17:36 UTC Modified: 2000-10-05 21:57 UTC
From: sgarner at gameplanet dot co dot nz Assigned:
Status: Closed Package: Documentation problem
PHP Version: 4.0.2 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: sgarner at gameplanet dot co dot nz
New email:
PHP Version: OS:

 

 [2000-10-03 17:36 UTC] sgarner at gameplanet dot co dot nz
Using the second argument (arr) doesn't seem to work. No elements will be inserted into the array by parse_str, and variables will still be created in the current scope.

Example:

<?php
  $querystring = "foo=bar&bar=foo";
  parse_str($querystring, $a);

  var_dump($a);
?>

Will output "NULL", and:

<?php
  var_dump($foo);
?>

...will output "bar".

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-10-05 21:57 UTC] stas@php.net
This was added after 4.0.2. Wait for 4.0.3 to be out RSN.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Mon Jun 15 09:00:02 2026 UTC