<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: PHP5&#8217;s SimpleXML Now Passes CDATA Content</title>
	<atom:link href="http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/feed/" rel="self" type="application/rss+xml" />
	<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/</link>
	<description>A bunch of stuff I would have emailed you about.</description>
	<lastBuildDate>Wed, 04 Nov 2009 23:52:48 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Evan K</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-179031</link>
		<dc:creator>Evan K</dc:creator>
		<pubDate>Wed, 11 Jul 2007 14:27:35 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-179031</guid>
		<description>For anyone whoâ€™s still stuck using PHP 5â€™s simplexml before v5.1.0 (like me), you can use a fairly simple regex to filter any cdata and collapse them into regular text nodes:

function cdata_to_text($text) {
$result = preg_replace(&#039;/&lt;!\[CDATA\[(.*?)\]\]&gt;/ie&#039;, &quot;htmlentities(&#039;\1&#039;)&quot;, $text);
$result = str_replace(&quot;\&quot;&quot;, &quot;&quot;&quot;, $result);
return $result;
}</description>
		<content:encoded><![CDATA[<p>For anyone whoâ€™s still stuck using PHP 5â€™s simplexml before v5.1.0 (like me), you can use a fairly simple regex to filter any cdata and collapse them into regular text nodes:</p>
<p>function cdata_to_text($text) {<br />
$result = preg_replace(&#8217;/&lt;!\[CDATA\[(.*?)\]\]&gt;/ie&#8217;, &quot;htmlentities(&#8217;\1&#8242;)&quot;, $text);<br />
$result = str_replace(&quot;\&amp;quot;&quot;, &quot;&amp;quot;&quot;, $result);<br />
return $result;<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: James Constable</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-176008</link>
		<dc:creator>James Constable</dc:creator>
		<pubDate>Tue, 12 Jun 2007 08:05:55 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-176008</guid>
		<description>Thanks.  This was doing my head in for a couple of hours yesterday.  Thought my xml was at fault until i found this article.  Glad they&#039;ve fixed it.  Its a major oversight otherwise.</description>
		<content:encoded><![CDATA[<p>Thanks.  This was doing my head in for a couple of hours yesterday.  Thought my xml was at fault until i found this article.  Glad they&#8217;ve fixed it.  Its a major oversight otherwise.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: nico</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-168409</link>
		<dc:creator>nico</dc:creator>
		<pubDate>Tue, 06 Mar 2007 14:32:09 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-168409</guid>
		<description>thanx a lot for my nerves with this article !</description>
		<content:encoded><![CDATA[<p>thanx a lot for my nerves with this article !</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Morgan</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-131531</link>
		<dc:creator>Morgan</dc:creator>
		<pubDate>Tue, 12 Dec 2006 21:37:58 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-131531</guid>
		<description>Googled looking for a solution to simpleXml skipping text wrapped in CDATA nodes.  Got your page, and tossed in the libXml2 parameter.  Worked great!  Thanks bud!</description>
		<content:encoded><![CDATA[<p>Googled looking for a solution to simpleXml skipping text wrapped in CDATA nodes.  Got your page, and tossed in the libXml2 parameter.  Worked great!  Thanks bud!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bjorn</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-35264</link>
		<dc:creator>Bjorn</dc:creator>
		<pubDate>Fri, 14 Apr 2006 05:17:25 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-35264</guid>
		<description>Your comment system has some PHP errors:



WordPress database error: [Duplicate entry &#039;11257-php5&#039; for key 2]
INSERT INTO wp_bsuite_tags (`post_id`,`comment_id`,`tag`,`tag_raw`) VALUES (&#039;11257&#039;, 35263,&#039;php5&#039;, &#039;php5&#039;)

Warning: Cannot modify header information - headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 55

Warning: Cannot modify header information - headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 56

Warning: Cannot modify header information - headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 57

Warning: Cannot modify header information - headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-includes/pluggable-functions.php on line 247[tags]php errors[/tags]</description>
		<content:encoded><![CDATA[<p>Your comment system has some PHP errors:</p>
<p>WordPress database error: [Duplicate entry '11257-php5' for key 2]<br />
INSERT INTO wp_bsuite_tags (`post_id`,`comment_id`,`tag`,`tag_raw`) VALUES (&#8217;11257&#8242;, 35263,&#8217;php5&#8242;, &#8216;php5&#8242;)</p>
<p>Warning: Cannot modify header information &#8211; headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 55</p>
<p>Warning: Cannot modify header information &#8211; headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 56</p>
<p>Warning: Cannot modify header information &#8211; headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-comments-post.php on line 57</p>
<p>Warning: Cannot modify header information &#8211; headers already sent by (output started at /home/mais04/public_html/blog/wp-includes/wp-db.php:102) in /home/mais04/public_html/blog/wp-includes/pluggable-functions.php on line 247</p>
<p>[tags]php errors[/tags]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bjorn</title>
		<link>http://maisonbisson.com/blog/post/11257/php5s-simplexml-now-passes-cdata-content/comment-page-1/#comment-35263</link>
		<dc:creator>Bjorn</dc:creator>
		<pubDate>Fri, 14 Apr 2006 05:11:02 +0000</pubDate>
		<guid isPermaLink="false">http://maisonbisson.com/blog/post/11257/#comment-35263</guid>
		<description>I wish more shared hosts would pick up PHP5. All of mine are still using PHP4 and I don&#039;t have access to any of the new XML tools, and I&#039;m afraid to write any thing with PHP4 because they may upgrade and break my scripts. It&#039;s nice to see what there is, even if I can&#039;t use it.[tags]php5[/tags]</description>
		<content:encoded><![CDATA[<p>I wish more shared hosts would pick up PHP5. All of mine are still using PHP4 and I don&#8217;t have access to any of the new XML tools, and I&#8217;m afraid to write any thing with PHP4 because they may upgrade and break my scripts. It&#8217;s nice to see what there is, even if I can&#8217;t use it.</p>
<p>[tags]php5[/tags]</p>
]]></content:encoded>
	</item>
</channel>
</rss>