Jeff Barr <[EMAIL PROTECTED]> wrote:
Ok, that makes sense. I did some digging and it looks like the offending
code is:
                       case $xmlrpcString:
                                $rs.="<${typ}>" . htmlentities($val).

In xmlrpcval::serializeData. Do I simply need to write a function to replace
htmlentities? It would basically do what htmlspecialchars does,
and then translate everything that's non-ASCII into numeric entities. This
should not be too hard to do with strtr.

Just saw this come flying in the inbox. This issue is a major PITA when generating RSS with PHP as well. htmlentities() uses the old html entity table not any of the new-fangled XML entity tables. And underlying this is a whole rant about the sense or nonsense of encoding the payload into XML in order to use an XML envelope and distribution protocol, whether it's RSS, XMLRPC or SOAP (or REST, heh!).

If you do write an xmlentities() function do please release it and tell us all. It would come in handy in lots of situations.

Julian Bond Email&MSM: [EMAIL PROTECTED]
Personal WebLog:
M: +44 (0)77 5907 2173   T: +44 (0)192 0412 433

phpxmlrpc mailing list

Reply via email to