Answers for "website link regex stackoverflow"

1

website link regex stackoverflow

var regex = new RegExp("^(https:\\/\\/www\\.){1}([0-9A-Za-z-\\.@:%_+~#=]+)+((\\.[a-zA-Z]{2,3})+)(/(.)*)?(\\?(.)*)?";);

if(regex.test("http://google.com")){
  alert("Successful match");
}else{
  alert("No match");
}
Posted by: Guest on February-26-2021
1

website link regex stackoverflow

var regex = new RegExp("^(http[s]?:\\/\\/(www\\.)?|ftp:\\/\\/(www\\.)?|www\\.){1}([0-9A-Za-z-\\.@:%_\+~#=]+)+((\\.[a-zA-Z]{2,3})+)(/(.)*)?(\\?(.)*)?");

if(regex.test("http://google.com")){
  alert("Successful match");
}else{
  alert("No match");
}
Posted by: Guest on February-26-2021
1

website link regex stackoverflow

https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)
Posted by: Guest on February-26-2021

Browse Popular Code Answers by Language