XSLTProcessor->transformToURI()
Transform to URI
&reftitle.description;
XSLTProcessor
int
transformToURI
DOMDocumentdoc
stringuri
Transforms the source node to an URI applying the stylesheet given by the
method.
&reftitle.parameters;
doc
The transformed document.
uri
&reftitle.returnvalues;
Returns the number of bytes written or &false; if an error occurred.
&reftitle.examples;
Transforming to a HTML file
load('collection.xml');
$xsl = new DOMDocument;
$xsl->load('collection.xsl');
// Configure the transformer
$proc = new XSLTProcessor;
$proc->importStyleSheet($xsl); // attach the xsl rules
$proc->transformToURI($xml, 'file:///tmp/out.html');
?>
]]>
&reftitle.seealso;