At 09:20 PM 7/17/02 -0500, Michael Sims wrote:

>$superglobals = array("var1", "var2", "var3", "var4", "var5", "...");
>
>Now inside the function you can do this:
>
>function somefunction ($somevar) {
>
>   global $superglobals;
>   foreach($superglobals as $varname) {
>     global $$varname; //resolves to $var1, $var2, $var3, etc.
>   }
>
>   //Other stuff here
>
>}


You're working too hard!


function somefunction( $somevar ) {

global $suberglobals;

extract( $superglobals );

//Other stuff here

}

Rick



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to