(()=>{(function(){"use strict";let r=$(".form-validation")[0],s=new Pristine(r,{classTo:"form-item",errorClass:"has-error",errorTextParent:"form-item",errorTextClass:"text-danger"});s.addValidator(r.querySelectorAll("input[type='url']")[0],function(e){let t=/[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)?/gi,i=new RegExp(t);return!!(!e.length||e.length&&e.match(i))},"This field is URL format only",2,!1),$(r).on("submit",function(e){e.preventDefault();let t=s.validate();alert(t?"Form submitted successfully!":"Please correct the errors in the form.")})})();})();
