Cascading Style Sheets

Slides:



Advertisements
Similar presentations
Chapter 6 More CSS Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
Advertisements

Today CSS HTML A project.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 4 Key Concepts 1 Copyright © Terry Felke-Morris.
Advance CSS (Menu and Layout) Miftahul Huda. CSS Navigation MENU It's truly remarkable what can be achieved through CSS, especially with navigation menus.
ADVANCED CSS William Neely CEO, Piecewise.com. CSS FONTS AND TEXT CSS ‣ Line-height allows to indicate the amount of space between lines; allows for equal.
Unit 20 - Client Side Customisation of Web Pages
CSS normally control the html elements. Three Ways to Insert CSS There are three ways of inserting a style sheet: External style sheet Internal style.
More CSS CS HTML id attribute 2 Coding Horror! Our mission is to combine programming and “human” factors with geekiness! output  A unique ID for.
Lecture Cascading Style Sheets (CSS) Internal Style Sheets Classes.
MORE Cascading Style Sheets (The Positioning Model)
CSS Box Model. What is the CSS Box Model? The “Box Model” is a tool we use to lay out our web pages in a number of individual "boxes" or "containers".
Technologies for web publishing Ing. Václav Freylich Lecture 7.
CSS My favourite ICT lesson By Federico Boschi Cascading Style Sheets.
Ch 10 HTML and CSS Web Standards Solutions A Web Standardistas’ Approach.
Web sites Design: Cascading Style Sheet (CSS) (Cont’d) Dimensions and Position of Elements –Width and Height Space –Table Cell Padding –Left and Top Position.
>> The “Box” Model. Pre-requisite Create a new project in Netbeans called Week5 Create a new html file and name it box.html Create a new css file and.
CSS Fun damentals The Document Hierarchy Element Relationships The Box Model.
CSS Layout Cascading Style Sheets. Lesson Overview  In this lesson, you will learn:  CSS Box Model  CSS properties for border  CSS properties for.
CSS Layout Cascading Style Sheets. Lesson Overview  In this lesson, you will learn:  float & clear  display & visibility.
CSS Layout Cascading Style Sheets. Lesson Overview  In this lesson, you will learn:  CSS properties for margin  CSS properties for dimensions (width,
11/12/2015 Box Model Reed Crouch. 11/12/2015  HTML elements can be considered as boxes. In CSS, the term "box model" is used when referring to layout.
Web Design (12) CSS Introduction. Cascading Style Sheets - Defined CSS is the W3C standard for defining the presentation of documents written in HTML.
HTML and Dreamweaver November 11th. Agenda Box Model Displaying and positioning elements – Padding – Margin – Float – Display – Position HTML Demo.
Understanding CSS Cascading Style Sheets control the presentation of content in HTML pages Style Sheets separate formatting from the content –Styles defined.
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 Layouts. Recall Properties of Box – Border (style, width, color) – Padding – Margin – Display – Background – Dimension Welcome Padding Area Border.
CHAPTER 15 Floating and Positioning. FLOAT VS. POSITION  Floating an element moves it to the left or right, allowing the following text to wrap around.
WebD Introduction to CSS By Manik Rastogi.
CSS.
Laying out Elements with CSS
Cascading Style Sheets Layout
CSS Box Model.
CSS Box Model.
CSS Box Model.
Cascading Style Sheets Boxes
Google fonts CSS box model
CSS Layouts: Grouping Elements
Unit 3 - Review.
CS1220 Web Programming Saloni Chacha.
>> The “Box” Model
Box model.
Cascading Style Sheets (Layout)
>> CSS Layouts.
Chapter 6 More CSS Basics Key Concepts
Web Development & Design Foundations with HTML5 7th Edition
Cascading Style Sheets
Basics of Web Design Chapter 6 More CSS Basics Key Concepts
Fixed Positioning.
CSS Borders and Margins.
CSS Box Model.
MORE Cascading Style Sheets (The Positioning Model)
HTML5 Level I Session III
HTML5 Level I Session III
Box model, spacing, borders, backgrounds
Cascading Style Sheets
Basics of Web Design Chapter 6 More CSS Basics Key Concepts
CSS Box Model.
Basics of Web Design Chapter 6 More CSS Basics Key Concepts
The Box Model.
Floating and Positioning
CSS Box Model.
CSS and Class Tools.
CSS Box Model.
CSS Box Model.
Web Client Side Technologies Raneem Qaddoura
Web Programming and Design
ITI 133: HTML5 Desktop and Mobile Level I
Cascading Style Sheets
Positioning Boxes Using CSS
Presentation transcript:

Cascading Style Sheets CSS Layout Cascading Style Sheets

Lesson Overview In this lesson, you will learn: CSS properties for margin CSS properties for dimensions (width, height, centering) Ask one kid to sketch what other kids describe (magazine page that sketcher can’t see) Look at result—shortcomings? Sketch is probably not super-accurate Need a very specific, accurate page description language—HTML

Margin Properties Property Description Example Values margin Margin for all 4 sides: One value for all 4 sides In clock-wise order: Top Right Bottom Left 5px 2px 3px 3px 2px margin-top, margin-right, margin-bottom, margin-left Margin for one side of the box 10px

Margin Examples Notice that margins are always transparent (they don’t contain the elements background color, etc.)

Exercise Open boxes.html and boxstyles.css Apply margins to the boxes so there are empty spaces between them

CSS properties for dimensions width / height How wide or tall to make the element Block elements only px or %

Centering a block element Use auto margins Works best if width is set To center inline elements within a block element, use text-align: center;

Centering Example

Exercise Open boxes.html and boxstyles.css Center BOX1 Center the text within BOX2, BOX3 and BOX4

Exercise - Solution