Sunday, 9 August 2015

What is difference between HTML and XML

          XML Stands for Extensible markup Language. It was language that has been designed to describe the content, present under text document. So it was known as  describing language and also platform  independent .
                                      Any language that represents data in the form of Tags can be called as Markup Language and any thing that gets enclosed under angular braces is a tag.

                   HTML and XML are two different markup languages. where HTML is used for  Formatting content of text document and XML is used for describing content of a t ext document. So HTML formatting and XML was Describing Language. 
                    The software that understands HTML was HTML interpreter and in the case of XML it was XML Parser. both these were part of a browser. 

                     HTML is an error free Language where as XML is not, to create an XML document we need to satisfy a set of rules that were prescribed by W3C as following.

  • An XML Document has to be saved with .XML extension.
  • An XML Document cannot be left empty.
  • Data under XML document should be present only under tags, where every tag should have a start and end element.
Eg:   <Tag> 1 </Tag>

           <Tag id ="1" />


No comments:

Post a Comment