note 14334 added to function.parse-url.php

From: Date: Fri, 27 Jul 2001 01:23:40 +0000
Subject: note 14334 added to function.parse-url.php
Groups: php.notes 
Request: Send a blank email to php-notes+get-15889@lists.php.net to get a copy of this message
this function will make variables out of your $url["query"] string. you may need this if the url you're parsing is not the current document's (since in that case the variables will already exist): function array_i2v($a) { if (!is_array($a)) $a = split("[=&]", $a); for ($i = 0; $i < count($a); $i += 2) { global $$a[$i]; $$a[$i] = $a[$i+1]; } } array_i2v("one=two&three=four&five=six"); echo $one; http://www.php.net/manual/en/function.parse-url.php

« previous php.notes (#15889) next »