Forum Moderators: coopster
I am using the following code:
// if "site" = [webmasterworld.com...] ....
$site = strtolower($_GET['site']);
$delete = array("http://", "ftp://","www.");
$show = str_replace($delete, "", $site);
// $show will hold the value "webmasterworld.com"
this works! What doesn't work is if I put "site" as "http://www.webmasterworld.com/forum/89/images/whatever".
What is going wrong?
When a "URL" is passed to the script in this way:
?url=http://www.google.com
it works fine, but if the URL has variables in it like:
?url=http://www.google.com/?q=Webmaster+World&LANG=UK
it chops of the &LANG part because it is concidered as another variable. How can I take only the variable "url" as a complete string from "http://" to "UK"
Cheers
James