XML Debugger Source Code - PHP Example

Real life use

include_once("XMLDebugger.class.php");
$xml=<<<EOF
<?xml version='1.0' encoding='UTF-8'?>
    <rss xmlns:atom='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' version='2.0'>
        <channel>
            <atom:id>tag:blogger.com,1999:blog-8561868508709777690</atom:id>
            <lastBuildDate>Thu, 27 Aug 2009 15:17:51 +0000</lastBuildDate>
            <title>PHP developer and systems analist Thales Jacobi</title>
            <description>PHP developer Thales Jacobi. Some of my work and the web related topics that I'm interested at the moment. AJAX, with jQuery, high performance MySQL, XML and RDF/XML parsing and understanding, SEO technics and a more IT subjects.</description>
            <link>http://thalesjacobi.net/index.php</link>
            <managingEditor>noreply@blogger.com (Thales Jacobi)</managingEditor>
            <generator>Blogger</generator>
            <openSearch:totalResults>1</openSearch:totalResults>
            <openSearch:startIndex>1</openSearch:startIndex>
            <openSearch:itemsPerPage>25</openSearch:itemsPerPage>
            <item>
                <guid isPermaLink='false'>tag:blogger.com,1999:blog-8561868508709777690.post-3483277524508145444</guid>
                <pubDate>Mon, 24 Aug 2009 13:54:00 +0000</pubDate>
                <atom:updated>2009-08-27T05:10:33.714-07:00</atom:updated>
                <title>Plataform update</title>
                <description>Blogger.com is now my blog plataform. I was using MS Office Live system and now Google's blog engine. All my previous posts including PHP classes and articles will be posted here in a little while. Thanks for passing by.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8561868508709777690-3483277524508145444?l=www.thalesjacobi.com%2Findex.php'/></div></description>
                <link>http://www.thalesjacobi.com/2009/08/testing-blogger-ftp-post.html</link>
                <author>noreply@blogger.com (Thales Jacobi)</author>
                <thr:total xmlns:thr='http://purl.org/syndication/thread/1.0'>0</thr:total>
            </item>
        </channel>
    </rss>
EOF;

header("Content-type: text/xml"); 
$xml_debugger=new XMLDebugger('xml',$xml);
echo $xml_debugger->do_debug();
exit;