XML to UTF-8
Questions about XML that are not covered by the other forums should go here.
-
- Posts: 1
- Joined: Fri Jan 02, 2009 11:58 pm
XML to UTF-8
I have a client that is saying that my xml is not utf-8 and I am not sure how to check or validate that it is or is not.
At the top of the header I have
<?xml version="1.0" encoding="utf-8"?>
<RECIPES xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:///c:/nobackup/Recipe.xsd">
<RECIPE RECIPEID="2" TITLE="Escargots Red Lion" TTIME="60" CONVENIENCE="Gourmet" IMAGE="2.jpg" COURSE="Appetizers">
<INGS>
Does that not declare it UTF-8 and when I validate should it not notify me that is that it is not UTF-8 if that is the case?
At the top of the header I have
<?xml version="1.0" encoding="utf-8"?>
<RECIPES xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:///c:/nobackup/Recipe.xsd">
<RECIPE RECIPEID="2" TITLE="Escargots Red Lion" TTIME="60" CONVENIENCE="Gourmet" IMAGE="2.jpg" COURSE="Appetizers">
<INGS>
Does that not declare it UTF-8 and when I validate should it not notify me that is that it is not UTF-8 if that is the case?
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: XML to UTF-8
Post by sorin_ristache »
Hello,
specifies that the files uses the UTF-8 encoding. You can check that by reading the file with an XML parser from a command line or from an XML editor tool.
For example Oxygen reports such a problem when you open the file from menu File -> Open. If Oxygen does not report any encoding problem when you open the file then the file content stored in that file on disk can be decoded without problems to text characters using the UTF-8 encoding.
Regards,
Sorin
Yes, the declarationsrr wrote:Does that not declare it UTF-8 and when I validate should it not notify me that is that it is not UTF-8 if that is the case?
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
For example Oxygen reports such a problem when you open the file from menu File -> Open. If Oxygen does not report any encoding problem when you open the file then the file content stored in that file on disk can be decoded without problems to text characters using the UTF-8 encoding.
Regards,
Sorin
Return to “General XML Questions”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service