Re: How about a saveXHTML for the DOM?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michael Shadle wrote:
On Wed, Apr 8, 2009 at 8:58 PM, Michael A. Peters <mpeters@xxxxxxx> wrote:

Yes it should - I believe php 6 is suppose to be much better at native UTF8.
At least according to some blog I read somewhere (IE don't believe me
without reservation, it's third hand knowledge at best)

afaik you're right, it's supposed to be fully unicode. or at least -was-

however, how long until it is production stable... when i am sure
someone can hack together a patch to make saveHTML unicode capable :p


I did a little reading on the issue and I don't think php 6 will fix it.
The issue is with libxml2 - it mutilates utf8 when exporting to html and php function wraps the libxml2 function.

The solution?
I don't know - but perhaps using saveXML() and then using a translation tool (maybe xslt?) to convert to HTML.

I actually had a function I wrote using preg_replace (started out as a wordpress plugin someone else wrote) but it could not properly handle cdata blocks - I'll see if I can find it.

I don't use it anymore as I use saveHTML() now for html output.

Maybe running iconv on the output would fix it?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux