Highlighted

convert xml Cp1252 tot UTF-8

New Here ,
Feb 05, 2016

Copy link to clipboard

Copied

My site imports an xml file which is encoded in Cp1252 from a windows machine. But when i try to parse it I get the following error "Invalid encoding name Cp1252". Somehow my site which is a Linux machine can't read it.

Does anyone know how to resolve this?

My solution was converting it tot UTF-8. Changing the encoding attributes to UTF-8 does the trick but not on all xml files. Every now en then it runs into a character it doesn't know. Does anybody know how tot convert de character tot UTF-8 using coldfusion (11).

TOPICS
Advanced techniques

Views

1.0K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

convert xml Cp1252 tot UTF-8

New Here ,
Feb 05, 2016

Copy link to clipboard

Copied

My site imports an xml file which is encoded in Cp1252 from a windows machine. But when i try to parse it I get the following error "Invalid encoding name Cp1252". Somehow my site which is a Linux machine can't read it.

Does anyone know how to resolve this?

My solution was converting it tot UTF-8. Changing the encoding attributes to UTF-8 does the trick but not on all xml files. Every now en then it runs into a character it doesn't know. Does anybody know how tot convert de character tot UTF-8 using coldfusion (11).

TOPICS
Advanced techniques

Views

1.0K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Feb 05, 2016 0
New Here ,
Feb 07, 2016

Copy link to clipboard

Copied

I solved it by using xml-high-safe.cfc (https://github.com/bengarrett/devtidbits.com/blob/master/post_42/xml-high-safe.cfc) by Ben Garret, to make the conversion of the high characters.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Feb 07, 2016 0
BKBK LATEST
Adobe Community Professional ,
Feb 15, 2016

Copy link to clipboard

Copied

Nice. Please kindly mark it as the correct answer. It will help someone else in future.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Feb 15, 2016 0