Page 1 of 1

parse_url()

Posted: Tue Aug 01, 2006 11:56 am
by NiGHTFiRE
Hey,
I'm making so every user gets their own profile, but i need help witha few things.
Right now i'm using $_GET to get the user's information from a mysql database. But now i need to get the users information from the url.
The profile is like this profile?=_username_

And i need to do something so i get the _username_ from the url.
I hope i've stated my question well, if not i'll try to explain myself better.

Thanks

Posted: Tue Aug 01, 2006 1:00 pm
by feyd
$_SERVER['QUERY_STRING'] perhaps.

Posted: Tue Aug 01, 2006 2:06 pm
by NiGHTFiRE
Thanks, Now it returns =_username_

And replace the _username_ to the persons username.
How would i take away the =?
I've tryed with str_replace

Posted: Tue Aug 01, 2006 2:08 pm
by feyd

Posted: Tue Aug 01, 2006 4:18 pm
by NiGHTFiRE
thanks.
works now.