Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I learn XML 1.0 or XML 1.1?

I know that a well-formed XML 1.1 is not necessarily a well-formed XML 1.0 and vice-versa.

I want to learn xml formally and i was wondering whether i should learn XML 1.0 or XML 1.1? I mean would it be more effective to learn XML 1.0 or would it be more effective to learn XML 1.1?

I mean of course I know its best to read them both.. but i really only have the time to read one of them, so which would be "better" (more useful to me, me as in the average programmer)?

like image 602
Pacerier Avatar asked Jun 07 '11 05:06

Pacerier


1 Answers

Unless you have a specific requirement to work with XML 1.1 (which is very rare), you should read the XML 1.0 Recommendation.

Tim Bray, one of the original editors of the specification, has created an excellent annotated version of it which you can find at http://www.xml.com/axml/axml.html

For a bit more info/opinion on XML 1.1, check out what Elliotte Rusty Harold has to say here: http://www.ibiblio.org/xml/books/effectivexml/chapters/03.html
Summary:

Everything you need to know about XML 1.1 can be summed up in two rules:

  1. Don't use it.
  2. (For experts only) If you speak Mongolian, Yi, Cambodian, Amharic, Dhivehi, Burmese or a very few other languages and you want to write your markup (not your text but your markup) in these languages, then you can set the version attribute of the XML declaration to 1.1. Otherwise, refer to rule 1.
like image 132
alexbrn Avatar answered Sep 29 '22 07:09

alexbrn