How to Add XML Version 1.0 Encoding

How to Add XML Version 1.0 Encoding thumbnail
How to Add XML Version 1.0 Encoding

Although computers make all text look the same by the time a user is reading it, text documents are actually stored differently depending on a number of factors like the editor used to create the document, or the language the text is in (for example, English or Chinese). The storage method for a document is called its encoding. An XML document is a text document that stores data nested inside tags, and it is trivial to specify the encoding.

Instructions

    • 1

      Determine what encoding your XML editor is using. Where you find this information varies: some editors have a “Format” menu, others allow you to specify the encoding while you save the document. A couple common types of encoding are ISO-8859-1 and UTF-8.

    • 2

      Copy and paste the following line into the very top of your XML document:
      <?xml version="1.0" encoding=”” ?>

    • 3

      Type the encoding method you determined in Step 1 into the quotes after the word “encoding” in Step 2. For example, if your editor uses UTF-8 encoding, then the line should read:
      <?xml version="1.0" encoding=”UTF-8” ?>

    • 4

      Save your document. The encoding is now correctly specified in the head of the XML document.

Tips & Warnings

  • If you’re using Windows Notepad to edit your XML document, the default encoding is “ASCII.”

Related Searches:

References

  • Photo Credit Jupiterimages/Photos.com/Getty Images

Comments

You May Also Like

  • How to Add an XML Attribute

    The use of XML on the Internet is becoming ubiquitous. From storing local application information to sending large amounts of data around...

  • How to Specify Encoding for XML

    Developers who create programs to read and process XML files face an odd paradox when it comes to determining each file's encoding,...

  • What Is XML Encoding?

    Computers encode the characters in saved files in a number of possible ways. This encoding refers to how the characters are translated...

  • How to Create a Simple XML File

    XML files are written in order to store information in a hierarchical fashion for later querying either by a database or information...

  • XML Encoding & ASP

    Because various computers use different numerical values to represent character sets, XML provides a means for defining which character set is being...

  • How to Find XML Encoding

    Extensible Markup Language (XML) is an encoding standard that lets website programmers display data from a database. XML must be denoted using...

  • How to Create an XML Sitemap

    XML sitemaps are files written in a special version of XML that interacts with the Google search engine. Sitemaps tell the search...

Related Ads

Featured