Re: html entities
| From: | Kevin Waterson | Date: | Fri, 18 Jul 2003 15:41:12 +0000 |
| Subject: | Re: html entities | ||
| References: | 1 2 | Groups: | php.xml.dev |
| Request: | Send a blank email to php-xml-dev+get-167@lists.php.net to get a copy of this message | ||
This one time, at band camp, Derick Rethans <derick@php.net> wrote:
> It's mostly the sign of the start of a two-byte Unicode character. Did
> you set the output encoding to UTF-8?
ahh, this must be it, it is set in the xsl, I assumed it would be default with
the new dom. This is what I have...
// create new xsltprocessor
$proc = new xsltprocessor();
// create new domDocument
$dom = new domDocument;
// create new domDocument
$dom2 = new domDocument;
// load domDocument from string
$dom2->loadxml($xmlstring);
// load domDocument from string
$dom->load('my.xsl');
// import stylesheet from domDocument
$proc->importStylesheet($dom);
// create domDocument from transformation (returns domDocument)
$result = $proc->transformToDoc($dom2);
// output domDocument xml to string
print $result->savexml();
Kind regards
Kevin
--
______
(_____ \
_____) ) ____ ____ ____ ____
| ____/ / _ ) / _ | / ___) / _ )
| | ( (/ / ( ( | |( (___ ( (/ /
|_| \____) \_||_| \____) \____)
Kevin Waterson
Port Macquarie, Australia