Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

If you're getting that error then you don't really have XML, you've got something masquerading as XML and the usual tools aren't going to handle it (well-formed-ness is sort of a bare minimum "You must be this tall to ride" requirement for data to be XML). The normal way to embed data that might contain characters that would be mistaken for markup is to either embed it in <![CDATA[...]]> (presuming your data doesn't contain any embedded ]]>'s of course :), or to encode it using something like base64 so that there's nothing but vanilla characters (but then it's incumbent upon the receiver to reconstitute the original data).

Unfortunately both of those options are going to require you to get whatever's emitting the nauga-XML to fix their output (then again it's their problem for creating output that's not well formed to begin with . . .).

Update: And if you read the XML spec not being well-formed is a fatal error, and processors conforming to the spec are supposed to toss up their hands and halt normal processing.

The cake is a lie.
The cake is a lie.
The cake is a lie.

In reply to Re: binary data in XML by Fletch
in thread binary data in XML by sailortailorson

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?

What's my password?
Create A New User
Domain Nodelet?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (7)
As of 2023-09-21 12:31 GMT
Find Nodes?
    Voting Booth?

    No recent polls found