Presentation is loading. Please wait.

Presentation is loading. Please wait.

XML, XSL, XSLT, XHTML and others By Sean Hunter. Why XML?  XML was created to be a quick and easy way to provide structured data over the web.  Existing.

Similar presentations


Presentation on theme: "XML, XSL, XSLT, XHTML and others By Sean Hunter. Why XML?  XML was created to be a quick and easy way to provide structured data over the web.  Existing."— Presentation transcript:

1 XML, XSL, XSLT, XHTML and others By Sean Hunter

2 Why XML?  XML was created to be a quick and easy way to provide structured data over the web.  Existing HTML and SGML either did not allow arbitrary structure, or were too complex.  XML’s simplicity allows programmers to write parsers for it quickly and easily.

3 What is XML?  Extensible Markup Language  XML is a human readable database  XML is fully conformant SGML, but XML parsers do conform to all of SGML.  As any markup language, XML provides a way to create structure in a document

4 Elements of XML  XML declaration: Not required, however it provides information on how to process the XML documentNot required, however it provides information on how to process the XML document  Tags:,  Tags:,  Attributes:  Attributes:  Values: A’s Value  Values: A’s Value

5 Example One One Two Two One One </list>

6 Document Type Definitions  Provides a way to standardize an XML document  Declares what elements can exist, what elements can nest in other elements, how many of a element are allowed, what attributes are allowed on a element, etc.

7 Example The * means that a LIST element may contain zero or more ITEM’s. ITEM may contain either text (#PCDATA) or another LIST element.

8 XSL and XSLT  Extensible Stylesheet Language Transformations  Provides a method to transmute XML into already existing data structures such as HTML, PDF, GIF, etc.  Sometimes companies want to keep the XML hidden, and only provide the transmuted data, or simply provide a more humanly readable format of their data.

9 Example - XML <motd>xml.com</motd>

10 Example - XSLT <body> Current message of the day: Current message of the day: </body></html>

11 Result Current message of the day: xml.com

12 XHTML  One major problem that many web designers have is that their website will look different across multiple different web browsers. Something on Firefox may look different from something on Opera, and IE.  XHTML creates a much stricter form of HTML that should, ideally, only have one way to be displayed across all browsers.  Because HTML does not have to be valid form for a browser to display it, XTML is preferred on cell phones and similar devices due to needing less processing to fix broken code.

13 RDF  RDF: Resource Description Framework  A possible way of describing resources in the internet.  Ex (From xml.com): Tim Bray Tim Bray </rdf:Description>

14 RSS  RDF Site Summary  A news feeder that many websites use to provide information about news on their website in a standard format using XML.

15  XML.com http://www.xml.com/ XML.com features a rich mix of information and services for the XML community. en-us Normalizing XML, Part 2 http://www.xml.com/pub/a/2002/12/04/normali zing.html In this second and final look at applying relational normalization techniques to W3C XML Schema data modeling, Will Provost discusses when not to normalize, the scope of uniqueness and the fourth and fifth normal forms. Will Provost 2002-12-04  XML.com http://www.xml.com/ XML.com features a rich mix of information and services for the XML community. en-us Normalizing XML, Part 2 http://www.xml.com/pub/a/2002/12/04/normali zing.html In this second and final look at applying relational normalization techniques to W3C XML Schema data modeling, Will Provost discusses when not to normalize, the scope of uniqueness and the fourth and fifth normal forms. Will Provost 2002-12-04  

16 XPath/XQuery  XPath: Used in XSL to find a particular element. Ex: body//p[position()=1] to get the first element in  XPath: Used in XSL to find a particular element. Ex: body//p[position()=1] to get the first element in  XQuery: A programming language for use in XML  Example, combining XPath and XQuery to print the chapters in a book from an XML structure (Taken from xml.com): { let $book := document("mybook.xml")/book for $ch in $book/chapter return {$ch/title) } { let $book := document("mybook.xml")/book for $ch in $book/chapter return {$ch/title) }

17 References  O’Reilly’s XML.com  World Wide Web Consortium W3C.org


Download ppt "XML, XSL, XSLT, XHTML and others By Sean Hunter. Why XML?  XML was created to be a quick and easy way to provide structured data over the web.  Existing."

Similar presentations


Ads by Google