Help for this page
<ticket ... state="...." ....> <version="1.23.4.8"> ... <task> ... </task> .... </ticket>
foreach(@code){ if (m/^<ticket .*state="(.*)") { ... print "\n"; }