Cheers yannick :-)
A long time ago I wrestled with the new XSLT in PHP and I don´t want you to go through that hell I did ;-) Copy the code below and you save a lot of time (and hair).
$fileNameXML = "d:/apache/test.xml"";
$fileHandle = fopen($fileNameXML, "r") or die("Could not open XML file");
$fileContentXML = fread($fileHandle, filesize($fileNameXML)) or die("Could not read XML file");
$fileNameXSL = "d:/apache/test.xsl"";
$fileHandle = fopen($fileNameXSL, "r") or die("Could not open XSL file");
$fileContentXSL = fread($fileHandle, filesize($fileNameXSL)) or die("Could not read XSL file");
fclose($fileHandle);
$arguments = array('/xml' => $fileContentXML, '/xsl' => $fileContentXSL);
// Allocate a new XSLT processor
$xh = xslt_create();
// Process the document
$result = xslt_process($xh, 'arg:/xml', 'arg:/xsl', NULL, $arguments);
if ($result)
{
print $result . "\n";
}
else
{
print "<pre>\n";
print xslt_error($xh) . "\n";
print xslt_errno($xh) . "\n";
print "</pre>\n";
}
// Free the XSLT processor
xslt_free($xh);