Wednesday, April 6, 2011


if( XMLdocument.documentElement.tagName.toUpperCase() == 'HTML' ) { return;

$xml = new DomDocument();
$xml->load('http://www.howtocreate.co.uk/tutorials/jsexamples/emperors.xml');

$xsl = new DomDocument();
$xsl->load('style.xsl');

$xslt = new XsltProcessor();
$xslt->importStylesheet($xsl);

$transformation = $xslt->transformToXml($xml);
echo $transformation;

?>

No comments:

Post a Comment