vanleurth Posted February 13, 2011 Share Posted February 13, 2011 I'm using a preg_match pattern to qualify url before they get saved in a database. As such; $preg_match02 = "/^[a-zA-Z]+[:\/\/]+[A-Za-z0-9\-_]+\\.+[A-Za-z0-9\.\/%&=\?\-_]+$/i"; I was wondering where do I place the : so it can also qualify url pages such as; http://www.collegehumor.com/picture:1950895 Thank you in advance, V. Quote Link to comment Share on other sites More sharing options...
Psycho Posted February 14, 2011 Share Posted February 14, 2011 This should work $preg_match02 = "/^[a-zA-Z]+[:\/\/]+[A-Za-z0-9\-_]+\\.+[A-Za-z0-9\.\/%&=\?\-_\:]+$/i"; Quote Link to comment Share on other sites More sharing options...
vanleurth Posted February 14, 2011 Author Share Posted February 14, 2011 mjdamato, thank you for your help. This has solved the problem. V. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.