Estoy intentando aplicar una plantilla XSL a un XML y me estoy volviendo loco. Lo pruebo en local utilizando el MAMP y funciona, pero al subirlo a mi servidor recibo siempre un error.
El script:
Código:
<?php
// Load the XML source
$xml = new DOMDocument;
$xml->load('midocumento.xml');
$xsl = new DOMDocument;
$xsl->load('miplantilla.xsl');
// Configure the transformer
$proc = new XSLTProcessor;
$proc->importStyleSheet($xsl); // attach the xsl rules
echo $proc->transformToXML($xml);
?>
El error:
Cita: Warning: domdocument() expects at least 1 parameter, 0 given in /miservidor/test.php on line 4
Fatal error: Call to undefined function: load() in /miservidor/test.php on line 5
Supongo que es una tontería, si alguien me echa un cable estaré agradecido.