in reply to Re: simple regex for names or last names
in thread simple regex for names or last names

Hello,

I'm not sure, but is this question just asking to allow a field with aphabetical characters along with a - and . ?

Of course like davidrw, a name can also contain a '.

unless ( param('Company Name') =~ /^[\w.\'-]+$/) { print "Invalid characters in name. Only alphanumeric characters and + the following symbols . ' - _ are allowed."; }

Thanks,
perleager