inital commit
This commit is contained in:
7
webroot/js/helper.js
Normal file
7
webroot/js/helper.js
Normal file
@@ -0,0 +1,7 @@
|
||||
function isUrlValid(userInput) {
|
||||
var res = userInput.match(/(http(s)?:\/\/.)?(www\.)?[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&//=]*)/g);
|
||||
if(res == null)
|
||||
return false;
|
||||
else
|
||||
return true;
|
||||
}
|
||||
Reference in New Issue
Block a user