Re: XML and htmlentities conditionally?

From: Date: Sun, 29 Jan 2006 16:53:22 +0000
Subject: Re: XML and htmlentities conditionally?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-229423@lists.php.net to get a copy of this message
Brian V Bonini wrote:
On Sun, 2006-01-29 at 02:01, Adam Hubscher wrote:
I have a block of XML that looks as follows: <name>&lt;*_~_*&gt; Røyken VGS &lt;*_~_*&gt;</name>
My question is, can I in any way efficiently (i -stress- efficiently, if anyone read my previous XML and special characters post its a rather large XMl file (breaking 18mb now) and speed is of the essence) cause html_entity_decode to not decode those tags?
What's the end results your looking for? If you are trying to pass that data straight through the parser try wrapping it in CDATA. <name><![CDATA[&lt;*_~_*&gt; Røyken VGS &lt;*_~_*&gt;]]></name>
The information is used to keep a database up to date for a service that was created in order to provide more advanced functionality for the service that made it. The XML file is not -mine-, and to search for all the html entities and wrap them in cdata before parsing would be kinda silly I think :O So yea, thats what I was trying to avoid having to do :O

« previous php.general (#229423) next »