Server IP : 150.95.80.236 / Your IP : 18.116.65.1 Web Server : Apache System : Linux host-150-95-80-236 3.10.0-1160.105.1.el7.x86_64 #1 SMP Thu Dec 7 15:39:45 UTC 2023 x86_64 User : social-telecare ( 10000) PHP Version : 7.4.33 Disable Function : opcache_get_status MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/vhosts/pcu.in.th/uat.pcu.in.th/demo15/src/plugins/formvalidation/dist/es6/validators/ |
Upload File : |
export default function t(){const t=(t,e)=>{const s=t.split(/"/);const l=s.length;const n=[];let r="";for(let t=0;t<l;t++){if(t%2===0){const l=s[t].split(e);const a=l.length;if(a===1){r+=l[0]}else{n.push(r+l[0]);for(let t=1;t<a-1;t++){n.push(l[t])}r=l[a-1]}}else{r+='"'+s[t];if(t<l-1){r+='"'}}}n.push(r);return n};return{validate(e){if(e.value===""){return{valid:true}}const s=Object.assign({},{multiple:false,separator:/[,;]/},e.options);const l=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;const n=s.multiple===true||`${s.multiple}`==="true";if(n){const n=s.separator||/[,;]/;const r=t(e.value,n);const a=r.length;for(let t=0;t<a;t++){if(!l.test(r[t])){return{valid:false}}}return{valid:true}}else{return{valid:l.test(e.value)}}}}}