in reply to Regex help
Hello Angel,
From the query you have posted i observe the following.
The function is tripping because the ^(caret) is outside the brackets([]) They need to be inside.
Using the æ for testing is perfectly ok the regex performs perfectly, once the caret is placed within the brackets.
my $in = "æ";
if ($in !~ /\w/) {print "contains non alpha numeric characters!!"; } else {print 'its all OK (_)';}
This should clarify your doubts. Cheers!!!
Anandatirtha
|
|---|