[Solved] Any ideas why this simple code isnt working?
Your problem here is the use of each(). It remembers the index it has reached in the array so in your second loop there is nothing left to loop out so it evaluates to false. If you use reset() this should resolve the issue. while(list($get_key, $get_value) = each($HTTP_GET_VARS)) { if (!${$get_key}) { ${$get_key}=$get_value; } } … Read more