Skip to content
Thomas Weinert edited this page Jul 12, 2018 · 3 revisions

FluentDOM\CdataSection

FluentDOM\CdataSection extends DOMCdataSection and allows it to be cast to a string.

$document = new FluentDOM\Document();
$document->loadXml('<xml><![CDATA[Hello World!]]></xml>');
echo $document->documentElement->firstChild;

Output:

Hello World!
Clone this wiki locally