What XML version to use?

2019-06-15 00:58发布

I have an online shop where vendors can upload and import there articles in two formats.

  1. plain text (tab delimted)
  2. XML

Currently I'm using XML 1.0.

However I see there is also a version 1.1

At wikipedia it is stated that for most uses 1.0 will be OK to use. http://en.wikipedia.org/wiki/XML#Versions

It also states it uses the following Unicode encoding: Unicode 2.0 to Unicode 3.2.

In the fifth edition, XML names may contain characters in the Balinese, Cham, or Phoenician scripts among many others which have been added to Unicode since Unicode 3.2

Currently I only have a couple of 'latin' based languages but this may change in the future and I want to be prepared.

Are there any characters in Unicode 3.2 not supported for some languages? Is v1.0 safe to use for me?

If you need more info just let me know.

标签: xml xml-1.1
3条回答
Evening l夕情丶
2楼-- · 2019-06-15 01:23

XML 1.1 came out of a fanatical desire to be "inclusive" by supporting all the world's languages, including methods of writing Abyssinian that were only used for 15 years nearly a century ago. If you are one of the 99.99999% of the population who doesn't need to capture ancient manuscripts, XML 1.1 is a total waste of time.

查看更多
做自己的国王
3楼-- · 2019-06-15 01:24

Beyond non-useful things (like silly EBCDIC linefeeds), there is unfortunately one nice feature that XML 1.1 allows: ability to use character entities for Unicode/ASCII control characters other than LF/CR/Tab. Except that you still can not include nulls, even using character references.

So this is hardly enough to make one use 1.1, unless there is specific need to contain these characters.

查看更多
太酷不给撩
4楼-- · 2019-06-15 01:26

Use version 1.0.

You would only need to use version 1.1 if you are using certain non-ASCII characters in identifiers, EBCDIC line ending characters, or control characters (character codes 1 - 31).

Rationale and list of changes for XML 1.1

查看更多
登录 后发表回答