IST 221 Internet Concepts and Applications Introduction to XML II CSS and XSLT Style Sheets.

Slides:



Advertisements
Similar presentations
XML-XSL Introduction SHIJU RAJAN SHIJU RAJAN Outline Brief Overview Brief Overview What is XML? What is XML? Well Formed XML Well Formed XML Tag Name.
Advertisements

XML III. Learning Objectives Formatting XML Documents: Overview Using Cascading Style Sheets to format XML documents Using XSL to format XML documents.
CG0119 Web Database Systems Parsing XML: using SimpleXML & XSLT.
Cascading Style Sheets
HTML Overview - Cascading Style Sheets (CSS). Before We Begin Make a copy of one of your HTML file you have previously created Make a copy of one of your.
Technology Reviews :XSL Park, Ho-gun. What is XSL Extensible Style sheet LanguageExtensible Style sheet Language An XML-based language used to.
SPECIAL TOPIC XML. Introducing XML XML (eXtensible Markup Language) ◦A language used to create structured documents XML vs HTML ◦XML is designed to transport.
XSLT (eXtensible Stylesheet Language Transformation) 1.
XSL XSLT and XPath 11-Apr-17.
XML: Managing Data Exchange Stylesheets. Lesson Contents CSS The basic XSL file XSL transforms Templates Sort Numbering Parameters and Variables Datatypes.
1/18 ITApplications XML Module Session 5: Extensible Stylesheet Language (XSL)
“Cascading Style Sheets” for styling WWW information DSC340 Mike Pangburn.
1 CP3024 Lecture 9 XML revisited, XSL, XSLT, XPath, XSL Formatting Objects.
XML Unit 6 October 31. XML, review XML is used to markup data Used to describe information Uses tags like HTML –But all tags are user-defined –Must be.
XSL Unit 6 November 2. XSL –eXtensible Stylesheet Language –Basically a stylesheet for XML documents XSL has three parts: –XSLT –XPath –XSL-FO.
Chapter 10 © 2001 by Addison Wesley Longman, Inc. 1 Chapter 10 Sebesta: Programming the World Wide Web.
LBSC 690: Session 6 CSS, XML/XSLT Jimmy Lin College of Information Studies University of Maryland Monday, October 15, 2007.
4.01 Cascading Style Sheets
CM143 Week 4 Introducing CSS. Cascading Style Sheets A definition for the style in which an element of the webpage will be displayed Border width, colour,
COS 381 Day 16. Agenda Assignment 4 posted Due April 1 There was no resubmits of Assignment Capstone Progress report Due March 24 Today we will discuss.
Understanding HTML Style Sheets. What is a style?  A style is a rule that defines the appearance and position of text and graphics. It may define the.
Chapter 12 Creating and Using XML Documents HTML5 AND CSS Seventh Edition.
Chapter 8 Introduction to XML. © 2006 Pearson Addison-Wesley. All rights reserved Introduction - SGML is a meta-markup language - Developed in.
Dreamweaver -- CSS. Dreamweaver -- MX New icons are added in MX Most of the features commonly used in web design, and are same as FrontPage. New feature.
Cascading Style Sheets (CSS) 1.  What is CSS?  Why CSS?  How to write a CSS? 2.
IS432 Semi-Structured Data Lecture 5: XSLT Dr. Gamal Al-Shorbagy.
XP New Perspectives on XML Tutorial 6 1 TUTORIAL 6 XSLT Tutorial – Carey ISBN
CIS 451: XSL Dr. Ralph Westfall February, Problems With XML no formatting capabilities contra formatting tags like, etc. in HTML CSS can be used.
XP 1 CREATING AN XML DOCUMENT. XP 2 INTRODUCING XML XML stands for Extensible Markup Language. A markup language specifies the structure and content of.
WORKING WITH XSLT AND XPATH
I NTRO TO CSS IAT100 Spring I NTRO TO CSS Covered in this lesson: Overview What is CSS? Why to use CSS? CSS for Skinning your Website Structure.
1 WDMD 170 – UW Stevens Point WDMD 170 Internet Languages eLesson: CSS Introduction to Style Sheets (NON-audio version) © Dr. David C. Gibbs
 This presentation introduces the following: › 3 types of CSS › CSS syntax › CSS comments › CSS and color › The box model.
1 Introduction to Web Application Introduction to XML.
CSS CSS is short for C ascading S tyle S heets. It is a new web page layout method that has been added to HTML to give web developers more control over.
XML About XML Things to be known Related Technologies XML DOC Structure Exploring XML.
WRT235: Writing in Electronic Environments Basic CSS.
CITA 330 Section 6 XSLT. Transforming XML Documents to XHTML Documents XSLT is an XML dialect which is declared under namespace "
XSLT Kanda Runapongsa Dept. of Computer Engineering Khon Kaen University.
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter X IXXXXXXXXXX XXXXXX.
CIS 375—Web App Dev II XSL. 2 XSL Introduction XSL stands for _____________________________. XSL is the language used for manipulating and displaying.
Lecture 11 XSL Transformations (part 1: Introduction)
CS134 Web Design & Development Cascading Style Sheets (CSS) Mehmud Abliz.
Waqas Anwar Next SlidePrevious Slide. Waqas Anwar Next SlidePrevious Slide XML XML stands for EXtensible Markup Language.
1 Introduction  Extensible Markup Language (XML) –Uses tags to describe the structure of a document –Simplifies the process of sharing information –Extensible.
XML technologies for text encoding Tamás Váradi
COS 381 Day 14. Agenda Questions?? Resources Source Code Available for examples in Text Book in Blackboard
Jennifer Widom XML Data Introduction, Well-formed XML.
Cascading Style Sheets CSS. Source W3Schools
Unit 3 — Advanced Internet Technologies Lesson 11 — Introduction to XSL.
 XSL – Extensible Style Sheet Language  XSLT – XSL Transformations › Used to transform XML documents to other formats,like HTML or other XML documents.
Web Design (12) CSS Introduction. Cascading Style Sheets - Defined CSS is the W3C standard for defining the presentation of documents written in HTML.
CSS Cascading Style Sheets A very brief introduction CSS, Cascading Style Sheets1.
1 XMLXSL(T) and CSS NOEA/PQC (rev. fen) 2007 Stylesheets CSS:Cascading Style Sheets XSL(T):eXtended Stylesheet Language (Transformations)
How to… Cascading Style Sheets. How to Insert a Style Sheet When a browser reads a style sheet, it will format the document according to it. There are.
XSLT: How Do We Use It? Nancy Hallberg Nikki Massaro Kauffman.
Department of Computer Science, Florida State University CGS 3066: Web Programming and Design Spring
NASRULLAHIBA.  It is time to take your web designing skills to the next level with Cascading Style Sheets (CSS). They are a way to control the look and.
Rendering XML Documents ©NIITeXtensible Markup Language/Lesson 5/Slide 1 of 46 Objectives In this session, you will learn to: * Define rendering * Identify.
1 Cascading Style Sheet (CSS). 2 Cascading Style Sheets (CSS)  a style defines the appearance of a document element. o E.g., font size, font color etc…
CASCADING STYLE SHEET CSS. CSS stands for Cascading Style Sheets Styles define how to display HTML elements Styles were added to HTML 4.0 to solve a problem.
CSS Introductions. Objectives To take control of the appearance of a Web site by creating style sheets. To use a style sheet to give all the pages of.
In this session, you will learn to:
CSS Cascading Style Sheets
Creating an XSLT Style Sheet for Formatting Data
XSLT 1.0.
Website Design 3
XML Data Introduction, Well-formed XML.
Unit 6 - XML Transformations
Presentation transcript:

IST 221 Internet Concepts and Applications Introduction to XML II CSS and XSLT Style Sheets

Display XML Documents with Style Sheets Two type of style sheets could be used to provide style information for the elements in the xml document –CSS : lists element’s css attributes and associated values –XSLT: contains templates that describe the desired document structure into which the data of an xml document can be inserted.

Display XML Documents with CSS Create a CSS that lists all the style rules for the Elements in the xml document. element_1{style_ attr1: value1; style_att2:value_2} Examples of style attributes: color, font- size, margin-left, and display. –Attribute “display” takes on two values: inline (default) and block.

Display XML Documents with CSS To connect the external CSS to the xml document, include the following statement in the xml document where would you add this statement? Put this after xml declare and before root element.

Display XML Documents with XSLT Style Sheets XSL Extensible Stylesheet Language XSL transformation (XSLT) –Transform an XML document into different form, in particular, HTML A XSLT style sheet contains one or more templates that describe the desired document format and structure.

XSLT Structure A XSLT style sheet is an xml document containing one root element: xsl:stylesheet and one or more templates under the root element. –i.e. XML declaration needs to be included:what is this? Stylesheet tags <xsl:stylesheet version = “1.0” xmlns:xsl = “ ” xmlns = “ ”> …………….template goes here.

XSLT Structure (continued) Template tags: to specify the structure and display for elements on the associated xml file structure rules for root element structure rules for element “plane” Close with tag

XSLT Structure (continued) value-of tag: to display the value of a element value of select = “plane/[year]” for-each tag: to display siblings. –select each child-element of a specific element and create a loop. HTML tags could be used to specify content.

Merge an XSLT stylesheet into an XML Document like a mail merge An XSL style sheet is saved as an.xsl file Add the following statement into the corresponding XML document

Exercises 8.2 Implement an external planes.css for planes.xml. Include the following style rules: ad ( style attributes and associated values) –display: block –margin-top: 15 px –color: blue year, make and model –color: red –font-size: 16pt color, description –display: block –margin-left: 20 px –font-size: 16pt

Exercises seller –display: block –margin-left: 15 px –font-size: 14pt location –display: block –margin-left: 40 px city, state –font-size: 12pt Connect the CSS to planes.xml from Ex 8.1 Display the file planes.xml

Exercises Exercises 8.3: download xslplane.xml and xslplane.xsl Exercise 8.4: download xslplanes.xml and xslplanes.xsl We will be discussing the structures of the two set of files Question: What are the differences between using CSS and XSL style sheets for an XML document?