[SOLVED] file.php?var_value instead of file.php?variable=var

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
RSimpson
Forum Newbie
Posts: 2
Joined: Wed Aug 04, 2004 6:38 am

file.php?var_value instead of file.php?variable=var_value

Post by RSimpson »

Hi folks,

I've been noticing that some sites are using urls similar to this: http://www.somesite.com/[i]index.php?home[/i]
Does anybody know how I would go about implementing this? I've tried just using $_GET as a stand alone variable but that didn't work, I also tried using $_GET[0] in case it had assigned the value to the first element in the array but again no such luck.

If anybody can help me out it would be greatly appreciated. :)


Cheers,
Robert
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Code: Select all

$_SERVER['QUERY_STRING']
RSimpson
Forum Newbie
Posts: 2
Joined: Wed Aug 04, 2004 6:38 am

Post by RSimpson »

Thanks that did the trick :D


Cheers,
Robert
Post Reply