unit 5 - cascading style sheets (css) xml - level i basic

Post on 21-Jan-2016

216 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Unit 5 - Cascading Style Sheets (CSS) www.profburnett.com

XML - Level I Basic

Copyright © Carl M. Burnett

Unit 5 - Cascading Style Sheets (CSS)

Unit objectives Identify the benefits and limitations of styling

XML documents with CSS, and link an XML document to a style sheet.

Apply simple CSS styles to an XML document.

7/14/2013 2

Copyright © Carl M. Burnett

Topic A Topic A: CSS and XML Topic B: CSS styles

7/14/2013 3

Copyright © Carl M. Burnett

Overview of Cascading Style Sheets

CSS specifications control a document’s appearance

Several stages of CSS1, CSS2, and now CSS3 specifications are in development CSS3 is modular

W3C provides a CSS Validation Service at its Web site

7/14/2013 4

Copyright © Carl M. Burnett

Linking to external style sheets Syntax: Prolog

<?xml-stylesheet type=“text/css”

href=“stylesheetname.css” ?>

7/14/2013 5

Copyright © Carl M. Burnett

External style sheet reference

7/14/2013 6

Copyright © Carl M. Burnett

Processing external style sheets File is passed to XML parser which reads the

prolog with the declaration (stylesheetname.css) and retrieves that file

Parser passes data from both files to browser Processes the data and displays the result

7/14/2013 7

Copyright © Carl M. Burnett

Student Exercise Topic A – CSS & XML A-1: Linking a XML Document to a CSS Style

Sheet

7/14/2013 8

Copyright © Carl M. Burnett

Unit summary Learned how to identify the benefits and

limitations of styling XML documents with CSS Learned how to link an XML document to a style

sheet.

7/14/2013 9

top related