can someone check this for me
Posted: Mon Nov 30, 2009 6:05 am
both of these are suposed to check url is in correct format?
this should only alow http:// with domain name
with no folder extentions
this should alow as above but with folder ext
this should only alow http:// with domain name
with no folder extentions
Code: Select all
if(!preg_match("/^http://[0-9a-zA-Z-.].[a-zA-Z]{2,3}$/", $_POST[linkto]))Code: Select all
if(!preg_match("/^http://(www.[0-9a-zA-Z][0-9a-zA-Z-][0-9a-zA-Z]|[0-9a-zA-Z][0-9a-zA-Z-][0-9a-zA-Z]).[a-zA-Z]{2,3}[0-9a-zA-Z/-_.]$/", $_POST[linkfrom]))