demo.xml
<jdoc> <doku kategory="Info">Wiki</doku> </jdoc>
Get the whole XML document or a part of it.
<?php $xml = JFactory::getXML('demo.xml'); echo '<pre>'; echo htmlentities($xml->asFormattedXML()); echo '</pre>';
Output:
Die "komprimierte" Ausgabe, z.B. zur Verwendung in Streams:
$xml->asFormattedXML(true)
<jdoc><doku kategory="Info">Wiki</doku></jdoc>
Output only a part of the document:
$xml->doku->asFormattedXML()
<doku kategory="Info">Wiki</doku>
demo.xml
Get the whole XML document or a part of it.
Output:
Die "komprimierte" Ausgabe, z.B. zur Verwendung in Streams:
Output:
Output only a part of the document:
Output: