The link you provided, http://paste.pocoo.org/show/112749/, points to an html document that describes an xml file, not the xml file itself (if you don't believe me, go to the link and "View-->Page Source" in your browser). If you're really trying to parse this as xml, that would be a problem.

Also, in future posts, please enclose code samples using the "code" tag. It makes them alot easier to read.

Ok, your program is a mess, but I think your real question is how to modify values and output back to xml while preserving the CDATA tags? If so, perhaps XML::Twig is what you want. It is discussed in this thread over at perl monks http://www.perlmonks.org/?node_id=701522.

your sample for me start with 'fld', call the handler and parse. What is, if i will change CDATA field in fld name="migmonJobNum"? Or if i will take <property name ="doc-long" value =" Number of parallel Migration Monitor jobs. " /> </properties> to identify of CDATA