]> git.sesse.net Git - xml-template/blobdiff - php5-swig/simple.php
Fix some use-after-frees in the C++11 version.
[xml-template] / php5-swig / simple.php
index a5b7f04ff1a7ea5092166cb77da785dbcae1e294..919d9ee13532ba561e1801010a2f0c15a0c9439f 100644 (file)
@@ -1,11 +1,12 @@
 <?php
+include("xml-template.php");
 
-dl("XML_Template_SWIG.so");
 $doc = XML_Template_process_file('../xml/simple.xml', array( 
        'title' => 'A very basic example',
        '#hello' => 'Hello world!'
 ), true);
-output_to_fd($doc, 1);
+XML_Template_clean_whitespace($doc, true);
+print XML_Template_convert_doc_to_string($doc, true);
 
 ?>