Are Index\PHP\Games\ subdirectories? (with the wrong slash?) If so, you can look at the output of $PHP_SELF. You might be able to use a simple function such as explode
$parts[ ] = explode("\", $PHP_SELF);
then, $parts would contain each subdirectory. then you could form the menubar string this way:
$bar = $part[0] . "\" . $part[1] . "\" . $part[2];
The test=hi part is in $HTTP_GET_VARS
try this
foreach($HTTP_GET_VARS as $key=>$val){
print("key: $key val: $val<br>");
}
You can refer to test this way
$HTTP_GET_VARS[test]