Pattern Match

Looking for a Pattern Match in perl4 toEXCLUDE certain characters such as @#$ etc..
something like:
if ($string =~ /[       ]/) {
print "These are not allowed";
exit;
}
continue with program if characters are not present

donb1Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
icdConnect With a Mentor Commented:
exit if ($string =~ /[\@\$#]/);
0
 
donb1Author Commented:
Thanks
0
All Courses

From novice to tech pro — start learning today.