Any idea why this function doesn't work...
I get the following error:PHP Code:function ValidateURL($url)
{
if(!preg_match('/^(http|ftp|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:/~\+#]*[\w\-\@?^=%&/~\+#])?', $url))
{
return false;
}
else
{
return true;
}
}
Warning: preg_match() [function.preg-match]: Unknown modifier '~' in /Applications/MAMP/htdocs/domain.co.uk/public_html/classes/user.class.php on line 556



Reply With Quote
Bookmarks