I am wondering why this code is not working:
// check to see if string contains "HTTP://" in front
if(strpos($URL, "http://")) $URL = $URL;
else $URL = "http://$URL";
If it does find that the string doesn't contain "HTTP://" the final string is "HTTP://HTTP://foo.foo" if it contiains "http://" in front.
See Question&Answers more detail:os