I have an xml file
<text>
<defalut>This file has the following features:</defalut>
<value>
<ul>
<li><info>CSS text formatting </info></li>
<li><info>Text loaded from a XML</info></li>
<li><info>Scrolls with easing</info></li>
<li><info>Mouse wheel supported</info></li>
<li><info>HTML supported</info></li>
<li><info>Click on the bar to move the handle to that point</info></li>
<li><info>Supports images</info></li>
<li><info>The scrollbar hides if not needed</info></li>
<li><info>The scrollbar resizes proportonal to the text sizeq</info></li>
</ul>
</value>
<tittle>Lorem Ipsum</tittle>
</text>
I use xpath and xquery to parse this file
$xml_str1 = file_get_contents("file.xml");
echo $xml_str = $xml_str.$xml_str1;
$xml = simplexml_load_string($xml_str);
$nodes = $xml->xpath('//text');
but I only get the string. How can I save html tags as a result of if iam parsing <value>tag I get content without <ul>and <li>How to get full html content in a tag <value>, since it
Thanks in advance
source
share