The code below works fine on Mac OS X with an input string of "� is accented". It creates the file and when I open it in BBEdit on Mac or IE Explorer on Win then the accented characters display correctly. On Windows the same code (with path name changed and text entered into the field on win platform) creates an output file that with the string represented as "頩s accented".
Any ideas on how to get around this?
-- Trevor DeVore Blue Mango Multimedia [EMAIL PROTECTED]
Here is the code:
on mouseUp
put revCreateXMLTree("<test>" & text of field 1 & "</test>", false, true, false) into tTreeID
put "/Users/trevordevore/Desktop/test1.xml" into tPath
put revXMLRootNode(tTreeID) into tRootNodeID
get revXMLText(tTreeID)
open file tPath for binary write
write (uniDecode (GetBOM() & uniEncode (revXMLText(tTreeID, tRootNodeID), "UTF16"), "UTF8")) & \
to file tPath
close file tPath
end mouseUp
function GetBOM
set the useUnicode to true
return numToChar(abs(baseConvert("FEFF",16,10))) -- Thanks Dar :)
end GetBOM_______________________________________________ use-revolution mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/use-revolution
