Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^3: How can I use XML::Simple parser to read and parse greater then (>), less then (<) and ampersand (&) symbol..

by amias (Novice)
on Dec 12, 2012 at 11:36 UTC ( #1008490=note: print w/ replies, xml ) Need Help??


in reply to Re^2: How can I use XML::Simple parser to read and parse greater then (>), less then (<) and ampersand (&) symbol..
in thread How can I use XML::Simple parser to read and parse greater then (>), less then (<) and ampersand (&) symbol..

You should enclose them in a CDATA block to keep them safe from the parser , all parsers should respect this.

 <tag><![CDATA <?>&;]!> ]]></tag>

the only thing you cannot put in CDATA is ]]> as its the CDATA terminator , however if its essential then you could do something like

<tag><![CDATA ]]]]><![CDATA >]]></tag>

for the full info see http://www.w3schools.com/xml/xml_cdata.asp


Comment on Re^3: How can I use XML::Simple parser to read and parse greater then (>), less then (<) and ampersand (&) symbol..
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1008490]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2014-10-24 08:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (131 votes), past polls