Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: stripping characters from html

by almut (Canon)
on Aug 03, 2010 at 13:29 UTC ( #852656=note: print w/replies, xml ) Need Help??


in reply to stripping characters from html

I am finding certain characters are breaking the script.

In what way are they breaking the script?  Maybe you just need to entity-encode those characters (preferably use numeric entities (encode_entities_numeric()), as in contrast to HTML, in XML only very few named entities are predefined (i.e. work without explicit entity declarations)).   Does ∫ really cause an error?

Alternatively, try specifying an appropriate encoding (in the first line of the XML file: <?xml version="1.0" encoding="..."?>).

Or, as a last resort, simply strip everything outside of the ASCII range.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://852656]
help
Chatterbox?
[ambrus]: ambrus's scratchpad
[ambrus]: Also, I was wrong, apparently you have to support both periodic and one-shot timers in an AnyEvent backend
[Corion]: ambrus: That looks deceptively simple, but maybe that's simply all that's needed. Which would be great! I hope I get to test it tomorrow, thanks!!
[choroba]: Hm, unrelated question.
[ambrus]: I added a timer implementation to ambrus's scratchpad as well, again the whole thing is completely untested and probably has more bugs than lines
[choroba]: Anyone using anything to validate json contents of a REST service?

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (13)
As of 2016-12-08 12:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (141 votes). Check out past polls.