<?php

function my_output_handler($string) {
	$arguments = array('/_xml' => $string);
	$xsltproc = xslt_create();
	$html = xslt_process($xsltproc, 'arg:/_xml', 'mysheet.xsl', NULL, $arguments);
	if (!$html)
		$html = 'XSLT processing error: '.xslt_error($xsltproc)."\n";

	xslt_free($xsltproc);
	return $html;
}

ob_start("my_output_handler");

?>
<?echo '<?xml version="1.0" encoding="UTF-8"?>'."\n"?>
<article>
  <title>A Sample Article</title>
  <section>
    <para>
    This is a test paragraph in the first section.
    </para>
  </section>
</article>
<?


if($explicit_ob_flush==1) {
	ob_end_flush();
}


?>