JQuery URl Validation


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function checkURL(url)
  2. {
  3. var str=url;
  4. var filter=/www\.[A-Za-z0-9\.-]{3,}\.[A-Za-z]{3}/;
  5. if (filter.test(str))
  6. return true;
  7. else
  8. return false;
  9. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.