1 / 11

Overview of XML Mini-Primer

Overview of XML Mini-Primer. David E. González BSEE, MBA. What Is XML. XML is an acronym that stands for e X tensible M arkup L anguage. XML like HTML is a “dialect” of what I call “The Mother of All Markup Languages “ – SGML (Standard Generalized Markup Language)

Télécharger la présentation

Overview of XML Mini-Primer

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Overview of XMLMini-Primer David E. González BSEE, MBA

  2. What Is XML XML is an acronym that stands for eXtensibleMarkup Language. XML like HTML is a “dialect” of what I call “The Mother of All Markup Languages “ – SGML(Standard Generalized Markup Language) There has also been the advent of HTML code that has the best of both worlds, which is commonly referred to as XHTML, eXtensible Hypertext Markup Language or HTML5. Here too XHTML must be “Well-Formed” in order to be properly processed. Latest release is version 1.1 NOTE: XML is not a programming “language” in the truest sense, but a Markup Language. It is many times also referred to a XMLTechnology

  3. Anatomy of Example XML File Declaration <?xml version="1.0“ encoding="ISO-8859-1"?> <?xml-stylesheet href=“workorder.xsl" type="text/xsl"?> <?DOCTYPE workorder SYSTEM “workorder.dtd"?> <workorder priority=“ “ datedue=“ “><submitter>     <name first=“ “ last=“ “ />     <email> </email>     <account number=“ “ /></submitter><project title=“ “>     <url> </url>     <description> </description></project></workorder> Stylesheet Prolog Validation Root Tag Element Tag Child Tags of “submitter” tag Element Tag Child Tags of “project” tag Prolog - This section is the most important of the xml document. Tells browser or parser what to do with this document and what type of document this is (xml) & encoding used. Root tag – It’s the top-element, think of it as a bucket where you put in all your content. There is only one insatnce with opening and closing tags Element tag – Hierarchy of elements and sub-elements arranged in a logical manner. Based on Source: http://webdesign.about.com/library/weekly/aa092401a.htm

  4. Example of An XML File Here’s how the “skeleton” xml file looks like when filled with content. NOTE: Attributes as part of the Elements tags… <?xml version="1.0“ encoding="ISO-8859-1"?> <?xml-stylesheet href=“workorder.xsl" type="text/xsl"?> <?DOCTYPE workorder SYSTEM “workorder.dtd"?> <workorder priority="high" datedue="09/30/2001"> <submitter>    <name first="Jennifer" last="Kyrnin" />    <email>html@aboutguide.com</email>    <account number="11001100" /></submitter><project title="update aa051198.htm article">    <url>http://webdesign.about.com/library/weekly/aa051198.htm</url>    <description>    Please convert this article to the new article look and feel, with the side navigation and info.     </description>  </project></workorder> Modified from Source: http://webdesign.about.com/library/weekly/aa092401a.htm

  5. XHTML <?xml version=“1.0” encoding=“UTF-8”?> <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “DTD/xhtml1-strict.dtd”> <html xmlns=http://www.w3c.org/1999/xhtml xml:lang=“en” lang=“en”> <head> <title>Example XHTML Code</title> </head> <body> <p><font size=“3”>Maria Roberts</font></p> <p>< font size=“3”>12-11-1942</font></p>

  6. XML vs. HTML The major difference between HTML and XML is that XML code must be validated with an XML parser in order to be considered “Well-Formed.” In this respect XML is closer in behavior its parent language (SGML) XML Decouples Data From Presentation XML was Designed to Describe Data HTML was Designed to Display Data http://courses.cs.vt.edu/~cs1204/XML/htmlVxml.html http://www.techrepublic.com/blog/10-things/10-things-you-should-know-about-html5/

  7. XML FamilyTechnologies • XML Namespace: • Display • (Browser) • XHTML • XSLT • XSL • XSL-FO • SVG • Modeling • (Validation) • XML Schema • DTD • RDF • Manipulation • (Parse) • DOM • SAX • XMLTask • Querying • (Database) • XLink • XQL • XPath XHTML – eXtensibleHyperTextMarkup Language XSLT – eXtensibleStylesheet Language Transformation XSL – eXtensibleStylesheet Language XSL-FO – eXtensibleStylesheet Language - Formatting Objects SVG – Scalable Vector Graphics XSD - XML Schema DTD – Document Type Definition RDF – Resource Description Framework DOM – Document Object Model SAX – Simple API for XML XMLTask – Uses Apache Ant XLink– XML Link XQL – XML Query Language XPath - XML Path http://www.xml.com/lpt/a/1297

  8. Benefits of XML* • Simplicity • Openness • Application & Platform Neutral • Extensibility • Self-description • Contains machine-readable context information • Separates content from presentation • Supports multilingual document & Unicode • Facilitates the comparison & aggregation of data • Can embed multiple data types • Can embed existing data • Provides a “one-server view” for distributed data • Rapid adoption by industry There are over 100+ different XML dialects and growing. For example, Industry uses xml services or SOAP to exchange data and information. Enterprise level services use ebXML and integrates to ERP (Enterprise resource Planning) systems. Microsoft (Visual Studio) uses XML technologies as the backbone for their products. Android application are developed in WML & WAP (both XML dialect). Oracle has their own native XML functionality (> 10g). And the list goes on and on… * Reference: http://www.mulberrytech.com/papers/HowAndWhyXML/slide009.html

  9. How These Can Fit Namespaces – Gives you the ability to create and use different vocabularies in XML URI - Uniform Resource Identifier Used to avoid namespace collision. This is of great importance when using Namespaces

  10. Why I’m Here I’m getting up to speed with Perl, but would like to learn Python. It’s appears to be the most popular coding language out there.

  11. Thank You And Yes… XML does work in both Mac & Windows Environment. Even UNIX and other platforms – Truly Portable & Open

More Related