Without knowing the whole file I would recommend changing (.*) to (.+?) meaning "match at least one character but non-greedy"!
In general you should consider using one of the XML-moduls on CPAN...
Cheers Rolf
In reply to Re: regex matching issue
by LanX
in thread regex matching issue
by rahulgsp83
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |