Week 0534Styling XML1 Topics CSS – styling XML for screen presentation –Associating CSS with XML –Selectors –Element positioning –Element appearance XSL.

Slides:



Advertisements
Similar presentations
CSS CSS Precise Aesthetic Control. Cascading Style Sheets Though they can be put in HTML header, usually a separate page that the HTML links to Contains.
Advertisements

1/18 ITApplications XML Module Session 5: Extensible Stylesheet Language (XSL)
Working with Cascading Style Sheets
Cascading Style Sheets Scripting with Style. CSS versus HTML  Ways to format in HTML –HTML Tag extensions –Converting Text to images –Page Layout with.
Cascading Style Sheets Controlling the Display Of Web Content.
XP 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks Tutorial 7.
Cascading Style Sheets Controlling the Display Of Web Content.
Tutorial 4 Creating Special Effects with CSS
Cascading Style Sheet (CSS) Instructor: Dr. Fang (Daisy) Tang
Working with Cascading Style Sheets. 2 Objectives Introducing Cascading Style Sheets Using Inline Styles Using Embedded Styles Using an External Style.
CSS (Cascading Style Sheets): How the web is styled Create Rules that specify how the content of an HTML Element should appear. CSS controls how your web.
CSS: Cascading Style Sheets. 2 History HTML tags were originally designed to define the content of a document. The layout of the document was supposed.
Principles of Web Design 6 th Edition Chapter 4 – Cascading Style Sheets.
1 Web Developer Foundations: Using XHTML Chapter 9 Cascading Style Sheet Concepts.
Using Cascading Style Sheets. Introduction to Styles and Properties  Cascading Style Sheets (CSS) are a standard set by the World Wide Web Consortium.
Cascading Style Sheets CS3505. What are CSS? Method for adding style attributes consistently to HML tags Cascading because styles are applied in order.
XP Tutorial 7New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks.
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.
Week 4.  Three ways to apply CSS: Inline CSS Internal style sheets ( header style information) External style sheets.
CIS 375—Web App Dev II XSLFO. 2 XSLFO IntroductionIntroduction XSLFO stands for Extensible Stylesheet Language ___________________. XSLFO is an _____-based.
CS105 INTRODUCTION TO COMPUTER CONCEPTS CASCADING STYLE SHEETS (CSS) Instructor: Cuong (Charlie) Pham.
Tutorial 4 Creating Special Effects with CSS. XP Objectives Work with CSS selectors Create styles for lists Create and apply class styles Create a rollover.
Principles of Web Design 6 th Edition Chapter 10 – Data Tables.
WORKING WITH CASCADING
New Perspectives on XML, 2nd Edition Tutorial 5 1 TUTORIAL 5 WORKING WITH CASCADING STYLE SHEETS.
XP New Perspectives on XML Tutorial 5 1 TUTORIAL 5 CSS Tutorial – Carey ISBN
Today’s objectives  Complete web page  Using xhtml & CSS  Adding CSS to documents Embed url(File);  CSS.
Tutorial 4 Creating Special Effects with CSS
CSS Positioning Creating Special Effects with CSS CS202 Working with Cascading Style Sheets (Chapter 4) CS202 1.
Doman’s Sections Information in this presentation includes text and images from
Cascading Style Sheets Class 1, Lecture 1 Rachel A Ober
Cascading Style Sheets by Pavlovic Nenad by. Presentation Contents  What is CSS?  Why CSS?  Types of Style Sheets  Style Sheets Syntax  Box Formatting.
Today’s objectives  Review  CSS | Rules | Declarations  HTML Structure document  Class asignment.
Website Development & Management Working with Style Rules Instructor: John Seydel, Ph.D. CIT Fall
CIS 1315 – Web Development for Educators CIS 1315 HTML Tutorials 3 & 4: Working With CSS.
Sheet 1XML Technology in E-Commerce 2001Lecture 7 XML Technology in E-Commerce Lecture 7 XSL Formatting Objects, Java Data Binding.
Tutorial #4 Formatting Text and Links. Tutorial #3 Review - CSS CSS format Selector { property1: value1; /* Comments */ } Embedded, In-Line, and External.
Today’s objectives  Review  CSS | Rules | Declarations  HTML Structure document  Class asignment.
MySQL and PHP Review CSS. Cascading Style Sheet (CSS) Style sheets are files or forms that describe the layout and appearance of a document. Cascading.
XP Tutorial 7New Perspectives on HTML and XHTML, Comprehensive 1 Working with Cascading Style Sheets Tutorial 7.
Lesson 03 // Cascading Style Sheets. CSS Stands for Cascading Style Sheets. We’ll be using a combination of Html and CSS to create websites. CSS is a.
Advanced Cascading Style Sheets (CSS) Lecture # July 2013.
CSS Tutorial 1 Introduction Syntax How to use style specifications. Styles.
Cascading Style Sheets II Robin Burke ECT 270. Outline Midterm solution CSS review CSS selection selectors pseudo-classes classes, ids div and span Final.
Cascading Style Sheets Robin Burke ECT 270. Outline Midterm The Layout Debate CSS properties Fonts Alignment Color CSS selection selectors pseudo-classes.
CSS WORKSHOP Design Principles for Web Standards.
Week 8 – Part 2 Page Layout Basics Key Concepts 1.
Lesson 15: Cascading Style Sheets. Objectives Identify ways to apply Web page formatting with Cascading Style Sheets (CSS1 and CSS2) using various methods.
Cascading Style Sheets Eugenia Fernandez IUPUI. CSS Purpose CSS allow you to specify the style in which your XML elements are displayed. CSS were originally.
XP Review 2 New Perspectives on JavaScript, Comprehensive1 Introducing Cascading Style Sheets Formatting Web Pages with CSS.
SDPL 20076: XSL Formatting1 6 XSL: Extensible Stylesheet Language n An advanced style language for XML documents: 1. Language for transforming XML documents:
CNIT 132 – Week 4 Cascading Style Sheets. Introducing Cascading Style Sheets Style sheets are files or forms that describe the layout and appearance of.
Tutorial 4 Creating Special Effects with CSS. New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition 2 Objectives Work with CSS selectors.
Tutorial 4 Creating Special Effects with CSS. New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition 2 Objectives Work with CSS selectors.
5 th ed: Chapter 4 4 th ed: Chapter 5 SY306 Web and Databases for Cyber Operations Slide Set #4: CSS.
Tutorial 4 Creating Special Effects with CSS. XP Objectives Work with CSS selectors Create styles for lists Create and apply class styles Create a rollover.
CSS Hadas Kahsay. Overview  What is CSS  Basic syntax of CSS Rules  How to link CSS style to html documents  Browsers and CSS  Advantages of CSS.
Cascading Style Sheets Primary readings Presentations Explain & review projects with class mates.
SDPL 2001Notes 6: XSL1 6 XSL: Extensible Stylesheet Language n An advanced style language for XML documents: 1. Language for transforming XML documents:
Cascading Style Sheets CSS2 - a bit more advanced.
CSS: Cascading Style Sheets Part II. Style Syntax.
CH 12 CSS Style Sheets 1. Objective What is CSS? Selecting elements Different rules for different media Importing style sheets 2.
Tutorial 3 Designing a Web Page with CSS
Blended HTML and CSS Fundamentals 3 rd EDITION Tutorial 3 Introducing Cascading Style Sheets.
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
1 CS428 Web Engineering Lecture 07 Font, Text & Background (CSS - II)
XP Tutorial 7New Perspectives on HTML and XHTML, Comprehensive 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks Tutorial 7.
Unit 3 - Review. Topics 1. Tag, Attribute, Value 2. CSS Rule Syntax + link 3. Categories of Selectors 4. Inline vs Block Tags 5. CSS Layout 6. CSS Box.
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.
Cascading Style Sheets Robin Burke ECT 270. Outline CSS properties Fonts Alignment Color CSS selection selectors.
Presentation transcript:

Week 0534Styling XML1 Topics CSS – styling XML for screen presentation –Associating CSS with XML –Selectors –Element positioning –Element appearance XSL FO – styling XML for printout –XSL FO vs CSS –XSL FO processing –Page layout and page masters –Flowing content into pages –Static content; headers and footers

Week 0534Styling XML2 CSS Basics Associating CSS with XML Selectors Element positioning: –Block vs inline –Tables –Lists Element appearance: –Borders and space –Fonts and texts –Colors

Week 0534Styling XML3 Associating CSS with XML Include a stylesheet processing instruction –, where an optional media attribute can be used for: screen tv print projection braille …

Week 0534Styling XML4 CSS Selectors Universal selector: * {font–size: medium} Matching descendants: person address {font–style: italic} Matching immediate children: person > address {font–style: italic} Matching first sibling: address + phone {font–weight: 800} Attribute selector: step[optional] {display: none}

Week 0534Styling XML5 Pseudoclasses and Pseudoelements Pseudclasses: :first–child :link :visited :hover … Pseudoelements: :first–letter :first–line :before :after

Week 0534Styling XML6 CSS Selector Exercise Exercise: –Run examples 1 through 10 from the ZVON CSS 2 tutorial, tmlBook.html

Week 0534Styling XML7 CSS Basics Associating CSS with XML Selectors Element positioning: –Block vs inline –Tables –Lists Element appearance: –Borders and space –Fonts and texts –Colors

Week 0534Styling XML8 Blocks vs. Inline (1) Edit your php.ini file: You will need to change the extension_dir setting to point to the directory where your extensions lives, or where you have placed your php_*.dll files. Please do not forget the last backslash. For example: extension_dir = c:/php/extensions/ blockinlined tekst

Week 0534Styling XML9 Blocks vs. Inline(2) Block–level element: {display: block} Inlined element (default): {display: inline} Invisible element: {display: none} Exercise: –Run example 48 from the ZVON CSS 2 tutorial, /example48.html.

Week 0635Styling XML10 Tables (1) There are ten display values that identify elements as parts of a table: table inline–table table–row–group table–header–group table–footer–group table–row table–row–group table–column–grouå table–column table–cell table–caption

Week 0635Styling XML11 Tables (2) Exercise –Run examples 12 through 16 from the ZVON CSS2 tutorial

Week 0635Styling XML12 Lists Lists are created by defining items as having display type list–item. List properties: –list–style–type –list–style–image –list–style–position Exercise: –Run examples 48 through 50 from the ZVON CSS2 tutorial

Week 0635Styling XML13 CSS Basics Associating CSS with XML Selectors Element positioning: –Block vs inline –Tables –Lists Element appearance: –Borders and space –Fonts and texts –Colors

Week 0635Styling XML14 Borders and Space (1) This document gives a quick, learn-by-example introduction to XSL Formatting Objects. Margin Border Padding Content

Week 0534Styling XML15 Borders and Space (2) Exercise –Run examples 12 through 16 from the ZVON CSS2 tutorial

Week 0534Styling XML16 Font Properties Several font properties can be set, particularly: –font-family –font-size –font-style –font-weight Exercise: –Run examples 30, 32, and 34 through 38 from the ZVON CSS2 tutorial

Week 0534Styling XML17 Text Properties Several text properties can be set, particularly: –text-indent –text-align –text-decoration –white-space Exercise: –Run examples 24, 28, and 29 from the ZVON CSS2 tutorial

Week 0534Styling XML18 Colors Several properties can be set for changing the color of various items, particularly: –color –background-color –border-color Colors may be specified in RGB-values or by using one of sixteen predefined names Exercise: –Run examples 17, 18, and 20 from the ZVON CSS2 tutorial

Week 0534Styling XML19 XSL Formatting Objects XSL FO an XML-application for creating paper documents: XSL FO namespace: – –Common to use fo as prefix XSL-FOpdfFOP XML XSL XSLT- processor

Week 0534Styling XML20 Similarities with CSS (1) Display types: –Inline –Block –List –Table Borders and margins: –Content may be encompassed by borders –Padding and margins control space around content

Week 0635Styling XML21 Similarities with CSS (2) Color, font and text properties: –Color: color, background-color, … –Fonts: font-family, font-size, font-style, font-weight, … –Alignment: text-align Space and break properties: –Space: space-after, space-before, … –Page break: break-after, break-before, …

Week 0635Styling XML22 XSL FO vs. CSS (Level 2) FO is right for printed matter: –Multiple column layout –Margin text –Running headers and footers –Automatic page cross reference by numbers CSS is right for web pages: –Straight forward; easy-to-learn and easy-to-use –Well understood and well supported by browsers –Can be applied directly to XML –No need for browser plugins But CSS Level 3 may change the story

Week 0635Styling XML23 Page Layout and Page Masters Page content divided in 5 regions: –Top of page ( region-before ) –Bottom of page ( region-after ) –Left sidebar ( region-start ) –Right sidebar ( region-end ) –Body of page ( region-body ) Body region should have margins making room for top, bottom and sidebars with a positive extent

Week 0635Styling XML24 Flowing Content into Pages <fo:simple-page-master master-name="titleMaster" …> </fo:simple-page-master

Week 0534Styling XML25 Static Content and Markers Headers and footers may contain a combination of static and running text Running text is defined as markers: <fo:retrieve-marker retrieve-class-name="division"/> … Introduction …

Week 0534Styling XML26 XSL FO Resources Tutorials: –W3 Schools –RenderX, –XML.com, fo/index.html and Tools: –Altova XMLSpy supports FO editing –Apache has a java–based FOP,