You are not grouping the REDIRECTURL element value in if statement, instead grouping only the REDIRECTURL tag. So $1 will have the value as REDIRECTURL U need to change the if statement as
Update:if ($data =~ m|<REDIRECTURL>(.*)</REDIRECTURL>| ) { print "Found: $1\n"; }
As suggested by johngg modified the if statement.
In reply to Re: regex pattern matches
by vinoth.ree
in thread regex pattern matches
by argos
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |