The method name was changed to be more correct.
This commit is contained in:
parent
abbd288509
commit
e5a4e2d8b6
|
|
@ -77,20 +77,20 @@ class PHPWord_Template
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Applies XSL transformation to XML template.
|
* Applies XSL style sheet to XML template.
|
||||||
*
|
*
|
||||||
* @param DOMDocument &$xslDOMDocument
|
* @param DOMDocument &$xslDOMDocument
|
||||||
* @param string $xslOptionsURI
|
* @param string $xslOptionsURI
|
||||||
* @param array $xslOptions
|
* @param array $xslOptions
|
||||||
*/
|
*/
|
||||||
public function applyXSLT(&$xslDOMDocument, $xslOptionsURI = '', $xslOptions = [])
|
public function applyXslStyleSheet(&$xslDOMDocument, $xslOptionsURI = '', $xslOptions = [])
|
||||||
{
|
{
|
||||||
$processor = new \XSLTProcessor();
|
$processor = new \XSLTProcessor();
|
||||||
|
|
||||||
$processor->importStylesheet($xslDOMDocument);
|
$processor->importStylesheet($xslDOMDocument);
|
||||||
|
|
||||||
if ($processor->setParameter($xslOptionsURI, $xslOptions) === \FALSE) {
|
if ($processor->setParameter($xslOptionsURI, $xslOptions) === \FALSE) {
|
||||||
throw new \Exception('Could not set values for the given XSL stylesheet parameters.');
|
throw new \Exception('Could not set values for the given XSL style sheet parameters.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$xmlDOMDocument = new \DOMDocument();
|
$xmlDOMDocument = new \DOMDocument();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue