This Code helps you: Php validation for a url inputed
if(preg_match(“/^[a-zA-Z]+[://]+[A-Za-z0-9-_]+.+[A-Za-z0-9./%&=?-_]+$/i”,$url))
{
echo “Valid URL”;
}
else
echo “You must supply a valid URL.”;
This Code helps you: Php validation for a url inputed
if(preg_match(“/^[a-zA-Z]+[://]+[A-Za-z0-9-_]+.+[A-Za-z0-9./%&=?-_]+$/i”,$url))
{
echo “Valid URL”;
}
else
echo “You must supply a valid URL.”;
Page views:1424