note 76412 modified in function.xsl-xsltprocessor-transform-to-uri by danbrown
| From: | danbrown@php.net | Date: | Fri, 28 Nov 2008 21:41:33 +0000 |
| Subject: | note 76412 modified in function.xsl-xsltprocessor-transform-to-uri by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-147256@lists.php.net to get a copy of this message | ||
Sometimes you don't want to transform to a file, an XML string (because you're using text
or html), or a DOMDocument.
To transform to standard output, you can use php://output
<?php
$proc->transformToURI($xml, 'php://output');
?>
To transform to a string (of HTML or text, instead of XML), you can use the above in conjunction
with output buffering.
<?php
ob_start();
$proc->transformToURI($xml, 'php://output');
$outputString = ob_get_flush();
?>
--was--
Sometimes you don't want to transform to a file, an XML string (because you're using text
or html), or a DOMDocument.
To transform to standard output, you can use php://output
<?php
$proc->transformToURI($xml, 'php://output');
?>
To transform to a string (of HTML or text, instead of XML), you can use the above in conjunction
with output buffering.
<?php
ob_start();
$proc->transformToURI($xml, 'php://output');
$outputString = ob_get_flush();
?>
http://php.net/manual/en/function.xsl-xsltprocessor-transform-to-uri.php