Encode & symbol in XML

tazmania

New Member
My Perl program is processing an XML file. Some entries may contain & symbols. And the parser breaks, saying: "Invalid name in entity".How can I process the file and encode &-s in all the incorrect entities?So, it will be something like this:\[code\]<words>text1 & text2</words> --> <words>text1 & text2</words>\[/code\]
 
Back
Top