*/ error_reporting( E_ALL ); require_once 'XML/Beautifier.php'; $fmt = new XML_Beautifier(); $result = $fmt->formatFile('test.xml', 'test2.xml'); if (PEAR::isError($result)) { echo $result->getMessage(); exit(); } echo "
"; echo htmlspecialchars(implode("",file('test.xml'))); echo ""; echo "
"; echo htmlspecialchars(implode("",file('test2.xml'))); echo ""; ?>