added regex for country names
This commit is contained in:
parent
ad68908657
commit
52fd5c9ccd
|
@ -508,6 +508,9 @@ function get_preg($argument, $regexp) {
|
|||
case 'nis_recipient':
|
||||
$pregexpr = '/^([[:alnum:]@\\.\\ \\_-])+$/u';
|
||||
break;
|
||||
case 'country': // Allow all letters and space
|
||||
$pregexpr = '/^[[:alpha:]]([[:alpha:] ])+$/u';
|
||||
break;
|
||||
}
|
||||
if ($pregexpr!='')
|
||||
if (preg_match($pregexpr, $argument)) {
|
||||
|
|
Loading…
Reference in New Issue