Quantcast
Channel: Adobe Community: Message List - ColdFusion
Viewing all articles
Browse latest Browse all 21760

Unexpected behavior in xmlparse, work-around found

$
0
0

If you read an XML file from another site like this:

 

 

<cfset myDoc=XMLParse("http://72.250.245.94/videoshare")>

 

<cfdump var = "#myDoc#">

 

 

the UTF-8 coding won't be handled correctly, and you will have unexpected characters when you display the XML data.

 

 

If you read the XML file like this:

 

 

<cfhttp

    url = "http://72.250.245.94/videoshare"

    charset = "UTF-8"

    result = "rawdoc">

   

<cfset myDoc=XMLParse(#rawDoc.filecontent#)>

 

<cfdump var = "#myDoc#">

 

The data will display as expected.


Viewing all articles
Browse latest Browse all 21760

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>