note 73980 modified in function.xsl-xsltprocessor-import-stylesheet by danbrown

From: Date: Fri, 28 Nov 2008 22:12:44 +0000
Subject: note 73980 modified in function.xsl-xsltprocessor-import-stylesheet by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-147313@lists.php.net to get a copy of this message
This is not a problem. You may set DOMDocument's documentURI property. Something like this <?php $xsl = new DOMDocument('1.0','UTF-8'); $xsl->loadXML(file_get_contents('/foo/bar/somefile.xsl'); $xsl->documentURI = '/foo/bar/somefile.xsl'; $xslProc = new XSLTProcessor(); $xslProc->importStylesheet($xsl); ?> and document('other.xsl') will work fine! --was-- This is not a problem. You may set DOMDocument's documentURI property. Something like this $xsl = new DOMDocument('1.0','UTF-8'); $xsl->loadXML(file_get_contents('/foo/bar/somefile.xsl'); $xsl->documentURI = '/foo/bar/somefile.xsl'; $xslProc = new XSLTProcessor(); $xslProc->importStylesheet($xsl); and document('other.xsl') will work fine! http://php.net/manual/en/function.xsl-xsltprocessor-import-stylesheet.php

« previous php.notes (#147313) next »