You could just try to load the url. If you can't load it, then it is not a valid url. You could do this:
$url = "http://www.yahoo.com/";
if(@file($url)){
print "$url is a valid url!";
}
else {
print "$url is an invalid url!";
}
There you go! If you are looking for something else, just tell me. Thanks
Acts 2:21
That if you confess with your mouth, "Jesus is Lord," and believe in your heart that God raised him from the dead, you
will be saved. For it is with your heart that you believe and are justified, and it is with your mouth that you confess
and are saved.