XML is a good language to use for structured documents that are shared over the internet. The role of elements in XML is Document Type Detail (DTD), which allows users to check that each component of document occurs in a valid place within the interchanged data stream. Users are able to check if they accidently put a third-level heading in a document before they entered a second-level heading, this is something that HTML can't do.
Some advantages of XML include:
- bring multiple files together to form compound documents
- identify where illustrations are to be incorporated into text files, and the format used to encode each illustration
- provide processing control information to supporting programs, such as document validators and browsers
- add editorial comments to a file.
There are some disadvantages to XML though, XML is not:
- a predefined set of tags, of the type defined for HTML, that can be used to markup documents
- a standardized template for producing particular types of documents.
One thing that I think is interesting about XML is that the language uses quotes within the code to determine the key figure of the code. An example of the quotes include:
<xs:sequence>
<xs:element name="to" type="xs:string"/>
<xs:element name="from" type="xs:string"/>
<xs:element name="heading" type="xs:string"/>
<xs:element name="body" type="xs:string"/>
</xs:sequence>
<xs:element name="to" type="xs:string"/>
<xs:element name="from" type="xs:string"/>
<xs:element name="heading" type="xs:string"/>
<xs:element name="body" type="xs:string"/>
</xs:sequence>
The elements, "to, from, heading, and body" are all in quotations to signal what the elements are in the document.
XML is an interesting markup language and seems like it would be a good language to learn for a job, but it seems like it would be unnecessary if a job requests me to write in HTML and use CSS.
No comments:
Post a Comment