Hallo zusammen,
ich ein absoluter PHP-Neuling und habe folgendes Problem:
Ich möchte eine XSL-Transformation durchführen und habe folgendes Bsp-Skript:
<?php
/* load the xml file and stylesheet as domdocuments */
$xsl = new DomDocument();
$xsl->load("hp.xsl");
$inputdom = new DomDocument();
$inputdom->load("hp.xml");
/* create the processor and import the stylesheet */
$proc = new XsltProcessor();
$xsl = $proc->importStylesheet($xsl);
$proc->setParameter(null, "titles", "Titles");
/* transform and output the xml document */
$newdom = $proc->transformToDoc($inputdom);
print $newdom->saveXML();
?>
Leider erhalte ich bei der Ausführung folgende Fehlermeldung: Fatal error: Class 'XsltProcessor' not found.
Habe gelesen, dass die Installation von libxslt notwendig ist. Ich verstehe aber beim besten Willen nicht wie.
Kann mir irgendjemand helfen?
Achso: Ich habe php5 auf WindowsXP installiert.
Viele Grüße.
ich ein absoluter PHP-Neuling und habe folgendes Problem:
Ich möchte eine XSL-Transformation durchführen und habe folgendes Bsp-Skript:
<?php
/* load the xml file and stylesheet as domdocuments */
$xsl = new DomDocument();
$xsl->load("hp.xsl");
$inputdom = new DomDocument();
$inputdom->load("hp.xml");
/* create the processor and import the stylesheet */
$proc = new XsltProcessor();
$xsl = $proc->importStylesheet($xsl);
$proc->setParameter(null, "titles", "Titles");
/* transform and output the xml document */
$newdom = $proc->transformToDoc($inputdom);
print $newdom->saveXML();
?>
Leider erhalte ich bei der Ausführung folgende Fehlermeldung: Fatal error: Class 'XsltProcessor' not found.
Habe gelesen, dass die Installation von libxslt notwendig ist. Ich verstehe aber beim besten Willen nicht wie.
Kann mir irgendjemand helfen?
Achso: Ich habe php5 auf WindowsXP installiert.
Viele Grüße.