4d30874fd792a From Joomla! Documentation Get the whole XML document or a part of it. 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: <jdoc> <doku kategory="Info">Wiki</doku> </jdoc> Die "komprimierte" Ausgabe, z.B. zur Verwendung in Streams: $xml->asFormattedXML(true) Output: <jdoc><doku kategory="Info">Wiki</doku></jdoc> Output only a part of the document: $xml->doku->asFormattedXML() Output: <doku kategory="Info">Wiki</doku> Elkuku 11:26, 14 January 2011 (CST) Edit comment Categories: Pages using deprecated source tagsPages with syntax highlighting errorsJXMLElementAsFormattedXMLCodeExampleMethodExample
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: