sub match_OK_phone_chars { my $val = shift; if ( $val =~ /^([-\d. \(\)]{10,}[extEX .-\d]*)$/ ) { return $1; } else { return undef; } }