COP 3813 Intro to Internet Computing Prof. Roy Levow Lecture 3.

Slides:



Advertisements
Similar presentations
1 Cascading Style Sheets Continued Different kinds of selectors in a style sheet –Simple- Pseudo-Class –Contextual- Pseudo-Element –Class Image Styles.
Advertisements

CSS The basics { }. CSS Cascading Style Sheets - language used to – describe html appearance & formatting Style Sheet - file that describes – how html.
1 Cascading Style Sheets™ (CSS) Outline 5.1 Introduction 5.2 Inline Styles 5.3 Embedded Style Sheets 5.4 Conflicting Styles 5.5 Linking External Style.
Cascading Style Sheets (CSS) “Styles” for short. Pg. 418.
Cascading Style Sheets
Today CSS HTML A project.
CHAPTER 7 STYLING CONTENT WITH CASCADING STYLE SHEETS.
Introducing CSS CIS 133 mashup Javascript, jQuery and XML 1.
Lecture 5 Use Cases and Style Sheets
1 Pengantar Teknologi Internet W03: CSS Cascading Style Sheets.
© 2010, Robert K. Moniot Chapter 5 CSS : Cascading Style Sheets 1.
 2002 Prentice Hall, Inc. All rights reserved. Chapter 4 – Cascading Style Sheets (CSS) Outline 4.1Introduction 4.2Inline Styles 4.3Creating Style Sheets.
Cascading Style Sheets. Slide 2 Lecture Overview Overview of Cascading Style Sheets (CSS) Ways to declare a CSS CSS formatting capabilities New features.
Using Cascading Style Sheets CSS Basics. Goals Understand basic syntax of Cascading Style Sheets (CSS) Understand basic syntax of Cascading Style Sheets.
Outline IS400: Development of Business Applications on the Internet Fall 2004 Instructor: Dr. Boris Jukic CSS: Cascading Style Sheets.
Cascading Style Sheet (CSS) Instructor: Dr. Fang (Daisy) Tang
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,
© 2007 D. J. Foreman CSS-1 Cascading Style Sheets Styles.
3.1 Cascading Style Sheets. Motto Fashions fade, style is eternal. —Yves Saint Laurent.
TECH2018 Multimedia and the Internet More about CSS and Page Layouts.
Working with Cascading Style Sheets. Introducing Cascading Style Sheets Style sheets are files or forms that describe the layout and appearance of a document.
Cascading Style Sheets Dreamweaver. Styles Determine how the HTML code will display Determine how the HTML code will display Gives designers much more.
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.
CSS Cascading Style Sheets By Garrett Garman. CSS Why use Style Sheets? Separates Appearance and Structure Modularity Quick and Easy changes Flexibility.
Cascading Style Sheets CSS.  Standard defined by the W3C  CSS1 (released 1996) 50 properties  CSS2 (released 1998) 150 properties (positioning)  CSS3.
CSS Introduction Cascading Style Sheets Provides a great deal of control over the presentation of the document HTML indicates both semantics of a document.
Cascading Style Sheets. Defines the presentation of one or more web pages Similar to a template Can control the appearance of an entire web site giving.
Tutorial 6 By Sam INE 1020 Introduction to Internet Engineering 1 DHTML & CSS Tutorial 6.
 2001 Prentice Hall, Inc. All rights reserved. 1 Chapter 6 - Cascading Style Sheets™ (CSS) Outline 6.1 Introduction 6.2 Inline Styles 6.3 Embedded Style.
Working with Cascading Style Sheets (CSS) Module 2: HTML Basics LESSON 5.
Introduction to Programming the WWW I CMSC Winter 2003 Lecture 7.
IS 360 Declaring CSS Styles. Slide 2 Introduction Learn about the three ways to declare a style Inline / embedded / external Learn about the effect of.
Cascading Style Sheets Part 1. CSS vs HTML HTML: Originally intended to markup structure of a document (,...,,,,,...) CSS Developing technology, CSS1,
 2008 Pearson Education, Inc. All rights reserved Cascading Style Sheets™ (CSS)
 2008 Pearson Education, Inc. All rights reserved Cascading Style Sheets™ (CSS)
June 2008 Florida Atlantic University Department of Computer Science & Engineering ISM 4052 –Internet Application Programming Dr. Roy Levow Session 1.
 2004 Prentice Hall, Inc. All rights reserved. Chapter 6 - Cascading Style Sheets™ (CSS) Outline 6.1 Introduction 6.2 Inline Styles 6.3 Embedded Style.
 Cascading Style Sheets (CSS) ◦ Used to specify the presentation of elements separately from the structure of the document.  Inline style ◦ declare.
DHTML. What is it? Dynamic HTML. Not a standard unlike HTML or Java It is a term applied by both Netscape and Microsoft to a collection of technologies.
Cascading Style Sheets
Cascading Style Sheets CSS.  Standard defined by the W3C  CSS1 (released 1996) 50 properties  CSS2 (released 1998) 150 properties (positioning)  CSS3.
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 (CSS). A style sheet is a document which describes the presentation semantics of a document written in a mark-up language such.
XP Review 2 New Perspectives on JavaScript, Comprehensive1 Introducing Cascading Style Sheets Formatting Web Pages with CSS.
 2008 Pearson Education, Inc. All rights reserved Cascading Style Sheets™ (CSS)
Introduction to CSS September 20, Introduction Cascading Style Sheets (CSS) –Separation of structure from presentation CSS guide and tutorial.
CSS: Cascading Style Sheets Part II. Style Syntax.
CSS Cascading Style Sheets *referenced from
- WE’LL LOOK AT THE POSITION PROPERTY AND HOW CSS RESOLVES CONFLICTS BETWEEN STYLING INSTRUCTIONS The position property; CSS specificity hierarchy.
Understanding CSS Cascading Style Sheets control the presentation of content in HTML pages Style Sheets separate formatting from the content –Styles defined.
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
Chapter 4 Frames and Cascading Style Sheets. Frames Frames divide a browser window into two or more separate pieces or panes, with each pane containing.
CSCI N241: Fundamentals of Web Design Copyright ©2004  Department of Computer & Information Science Using Cascading Style Sheets Module A: CSS Basics.
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.
Creating Web Documents CSS examples (do more later) Lab/Homework: Read chapters 15 & 16. Work on Project 3, do postings.
Internet & World Wide Web How to Program, 5/e 1. 2.
Chapter 6 - Cascading Style Sheets™ (CSS)
Cascading Style Sheets™ (CSS)
CSS: Cascading Style Sheets
Chapter 6 Cascading Style Sheets™ (CSS)
Cascading Style Sheets
IS333: MULTI-TIER APPLICATION DEVELOPMENT
DynamicHTML Cascading Style Sheet Internet Technology.
Cascading Style Sheets
Cascading Style Sheets™ (CSS)
DynamicHTML Cascading Style Sheet Internet Technology.
Web Design and Development
Cascading Style Sheets™ (CSS)
Presentation transcript:

COP 3813 Intro to Internet Computing Prof. Roy Levow Lecture 3

Cascading Style Sheets  Allow detailed formatting of web pages  Provide separation of structure from presentation (format)  Inline Style –Included directly in XHTML document –More limited capability

Inline Styles  “style” attribute can be added to many tags  Can alter characteristics such as –Font-size, specified in points –Font –Color  Name  Hexadecmimal number #rrbbgg

 Style is a quoted string with a series of elements of the form –Element_name: value1, value2, … –Separated by ;  Example: Fig. 6.1 Fig. 6.1Fig. 6.1

Embedded Style Sheet  Include style sheet information in same page   Style sheet elements </style>  Elements define new tags for styles –name { def } –Def has same form as inline style

Example Embedded Style Sheet  Fig. 6.2 Fig. 6.2 Fig. 6.2  Properties –font-family: font, modifier  Font = arial, times new roman, …  Modifier = sans serif –background color – font-size  Symbolic or numeric pt size  Classes specified as.name

Style Classes and Scope  Style applies to all nested elements  Style is used as new tag  Style class us used to modify an existing tag  Styles of nested components can override styles from ancestors  Styles mas specify a series of tags, applying only in that context “ul ul” applies in a sublist

Style Inheritance  Example Fig – a.nodec applies only to classes that have defined the attribute nodec – a:hover defines changed appearance when mouse is over item

External Style Sheets  File with extension.css contains style definitions –Example Fig  Document file link to style sheet <link rel = “stylesheet” type “text/css” href = “styles.css” /> –Example Fig 6.5 Fig 6.5Fig 6.5

Validation  CSS validator at

Positioning Elements  Property position – absolute for position relative to top left corner = (0,0) –Size is often in px, pixels –Relative to top, bottom, left, right –z-index specifies overlay order for overlapping items  1 is lowest  Example Fig 6.8 Fig 6.8Fig 6.8

Relative Positioning  Shift position with position: relative  span tag specifies range of application of a style  Example Fig 6.9 Fig 6.9Fig 6.9

Other Features  Backgrounds –Fig 6.8 Fig 6.8Fig 6.8  Element dimensions –Fig  Floating elements and text flow –Fig 6.10 Fig 6.10Fig 6.10  Borders –Fig 6.11, Fig 6.12 Fig 6.11Fig 6.12Fig 6.11Fig 6.12

User Style Sheets  Can override defaults and/or author styles  In IE set Accessability | Format documents using my style sheet –Example fig 6.16, 6.17,

JavaScript  Scripting languages are interpreted from source code  Based on Java  Object-oriented  Can be embedded in web pages  Examples fig 7.1, 7.2, 7.3 fig fig

JavaScript Dialogs  Can open various dialog windows  Use appropriate class  Java strings support usual C-style \ excape sequences  Example

JavaScript Input  Can open input window and retrieve input  Example fig

Programming in JavaScript  Has full programming capability –Example fig  Comparison Example fig