Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
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 taking refuge in the Monastery: (11)
As of 2014-12-22 18:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (126 votes), past polls