XML encoding oddities

Trevor DeVore lists at mangomultimedia.com
Mon Nov 10 09:33:05 EST 2008


On Nov 9, 2008, at 11:50 AM, Mark Smith wrote:

> So, finally, is there a way to encode xml documents as UTF-8 (or  
> whatever) without having to encode each part myself, and add the  
> encoding attribute to the header myself?

Mark,

Have you tried creating your XML tree with the encoding included?

put format("<?xml version=\"1.0\" encoding=\"UTF-8\"? 
 ><whatshappening></whatshappening>") into tXml
put revCreateXmlTree(tXml, true, true, false) into tTree
put revXmlRootNode(tTree) into tNode

I've done this in the past and then I pass UTF-8 encoded strings to  
the revXML handlers.

Regards,

-- 
Trevor DeVore
Blue Mango Learning Systems
ScreenSteps: http://www.screensteps.com
Developer Resources: http://revolution.bluemangolearning.com



More information about the use-livecode mailing list