1 Dreamweaver CS5 intermediate class by Cookie Setton Build a CSS website WITHOUT TABLES Just when you thought you were starting to understand HTML coding,

Slides:



Advertisements
Similar presentations
Copyright © 2003 Pearson Education, Inc. Slide 3-1 Created by Cheryl M. Hughes The Web Wizards Guide to XML by Cheryl M. Hughes.
Advertisements

HTML and CSS. HTML Hyper Text Markup Language Tells browser how to display text and images.
HIGH LEVEL OVERVIEW: CSS CSS SYNTAX CONSISTS OF A SET OF RULES THAT HAVE 3 PARTS: A SELECTOR, A PROPERTY, AND A VALUE. IT’S NOT NECESSARY TO REMEMBER THIS.
CSS Cascading Style Sheets. Objectives Using Inline Styles Working with Selectors Using Embedded Styles Using an External Style Sheet Applying a Style.
CSS Styling CSS Box Model & CS110: Computer Science and the Internet.
Cascading Style Sheets
Cascading Style Sheets
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 6 Key Concepts 1 Copyright © Terry Felke-Morris.
CSS Digital Media: Communication and design 2007.
Today CSS HTML A project.
Chapter 3 – Designing your web pages Dr. Stephanos Mavromoustakos.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 6 Key Concepts 1 Copyright © Terry Felke-Morris.
Very quick intro HTML and CSS. Sample html A Web Title.
Cascading Style Sheets. CSS stands for Cascading Style Sheets and is a simple styling language which allows attaching style to HTML elements. CSS is a.
Web Development & Design Foundations with XHTML Chapter 7 Key Concepts.
Cascading Style Sheets Basics. Why use Cascading Style Sheets? Allows you to set up a series of rules for all pages in a site. The series may be changed.
Principles of Web Design 5 th Edition Chapter Nine Site Navigation.
Cascading Style Sheets By: Valerie Kuna. What are Cascading Style Sheets? Cascading Style Sheets (CSS) are a standard for specifying the presentation.
Web Development & Design Foundations with XHTML Chapter 7 Key Concepts.
1 Web Developer & Design Foundations with XHTML Chapter 9 Key Concepts.
End User Computing An Introduction to CSS Sujana Jyothi Research Lab1, Callan Building, Department of Computer Science
Advance CSS (Menu and Layout) Miftahul Huda. CSS Navigation MENU It's truly remarkable what can be achieved through CSS, especially with navigation menus.
CSS BASICS. CSS Rules Components of a CSS Rule  Selector: Part of the rule that targets an element to be styled  Declaration: Two or more parts: a.
Building a Website: Cascading Style Sheets (CSS) Fall 2013.
Cascading Style Sheets Based on Castro, HTML for the WWW, 6 th edition Ron Gerton, Fall 2007.
1 Pengantar Teknologi Internet W03: CSS Cascading Style Sheets.
CIS 1310 – HTML & CSS 6 Layout. CIS 1310 – HTML & CSS Learning Outcomes  Describe & Apply the CSS Box Model  Configure Float with CSS  Designate Positioning.
Recognizing the Benefits of Using CSS 1. The Evolution of CSS CSS was developed to standardize display information CSS was slow to be supported by browsers.
CSS(Cascading Style Sheets )
CSW131 Steven Battilana 1 CSW 131 – Chapter 5 (More) Advanced CSS Prepared by Prof. B. for use with Teach Yourself Visually Web Design by Ron Huddleston,
Web Pages and Style Sheets Bert Wachsmuth. HTML versus XHTML XHTML is a stricter version of HTML: HTML + stricter rules = XHTML. XHTML Rule violations:
กระบวนวิชา CSS. What is CSS? CSS stands for Cascading Style Sheets Styles define how to display HTML elements Styles were added to HTML 4.0 to.
Class four: the box model and positioning. is an HTML tag which allows you to create an element out of inline text. It doesn’t mean anything! try it:
Unit 20 - Client Side Customisation of Web Pages
Chapter 8 Creating Style Sheets.
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.
Web Design with Cascading Style Sheet Lan Vu. Overview Introduction to CSS Designing CSS Using Visual Studio to create CSS Using template for web design.
Beginning Web Site Creation: Dreamweaver CS4. XHTMLCSS  Describes the structure  Content  Collection of styles  Formatting body { background-color:
Introducing Cascading Style Sheets  Cascading Style Sheet Basics  Creating Styles  Using Styles  Manipulating Styles  Text Formatting with CSS.
4.01 Cascading Style Sheets
Tutorial 3: Adding and Formatting Text. 2 Objectives Session 3.1 Type text into a page Copy text from a document and paste it into a page Check for spelling.
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.
Tutorial 6 Creating Tables and CSS Layouts. Objectives Session 6.1 – Create a data table to display and organize data – Modify table properties and layout.
1 What is CSS?  CSS stands for Cascading Style Sheets  Styles define how to display HTML elements  Styles are normally stored in Style Sheets  Styles.
 This presentation introduces the following: › 3 types of CSS › CSS syntax › CSS comments › CSS and color › The box model.
Lecture 2 - HTML and CSS Review SFDV3011 – Advanced Web Development 1.
Introducing Cascading Style Sheets. Cascading Style Sheet Basics  Cascading Style Sheet Basics  Creating Styles  Using Styles  Manipulating Styles.
Web Design (12) CSS Introduction. Cascading Style Sheets - Defined CSS is the W3C standard for defining the presentation of documents written in HTML.
1 Preparation for site Create a folder in MyDocuments: beavercheese. Create a subfolder, images Classes, career, DW beginner Download.
Understanding CSS Cascading Style Sheets control the presentation of content in HTML pages Style Sheets separate formatting from the content –Styles defined.
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.
WebD Introduction to CSS By Manik Rastogi.
CSS.
Cascading Style Sheets (CSS) Internal Style Sheets Classes
( Cascading style sheet )
Semester - Review.
Unit 3 - Review.
Creating Your Own Webpage
Cascading Style Sheets (Layout)
Web Development & Design Foundations with HTML5 8th Edition
Cascading Style Sheets
IS333: MULTI-TIER APPLICATION DEVELOPMENT
The Internet 10/13/11 The Box Model
Cascading Style Sheets
Exercise 9 Skills You create and use styles to create formatting rules that can easily by applied to other pages in the Web site. You can create internal.
Cascading Style sheet. What is CSS?  CSS stands for Cascading Style Sheets  Cascading: refers to the procedure that determines which style will apply.
Introduction to Cascading Style Sheets (CSS)
Introduction to Styling
Presentation transcript:

1 Dreamweaver CS5 intermediate class by Cookie Setton Build a CSS website WITHOUT TABLES Just when you thought you were starting to understand HTML coding, style sheets come along. It is not an absolute necessity that you know how to hand code CSS, but just like with HTML there are always going to be situations where it helps to at least understand what you are looking at. Another unique feature of CSS is that it can be used both in a document and outside of a document as an External Cascading Style Sheet. However, with all of your CSS in an external sheet you are able to make site wide changes that wouldn’t be possible if all of your CSS coding was only in the document. 1.External or linked (style.css) – no in code. 2.Internal or embedded (this document only) 3.Inline – not recommended. Next to text. In the first lessons we will keep the CSS IN This Document so that we can use different CSS styles within one folder. CSS elements: selector, declaration with the { } – Untitled Document – –body { –font-family: Arial, Helvetica, sans-serif; –color: #C06; –line-height: 2.0; –margin:0px; –padding:0px; –background:#000000; –} – ______________________________________________________________________________ Change tags – create a rule for an existing HTML rule Create Rules for p, H1, H2, h3, etc.

2 The code will look something like this: Lesson 1 body { font-family: Arial, Helvetica, sans-serif; color: #C06; line-height: 2.0; margin:0px; padding:0px; background:#000000;} p { color: #FFF;} h1 { color: #300; background-color: #F39;} h2 { color: #FC0; text-decoration: underline;} h3 { a: 1.5em; display: block; } The design page will look something like this:

3 Index1 - Create some tags: body, P, H tags - to generate text. Copy 5 paragraphs, save as lipsum.txt in (notepad) Page properties, insert parksbg, Copy lorem ipsum text & paste Select tag, use the pencil to edit or double click body in CSS styles panel (remove the p if necessary) –Type 16px, tahoma Separate some of the text for header tags –H tags, header tags: h1 – h6 ctrl+1= H1 – put the cursor inside the paragraph –Make h1, h2, h3. Select the tag, make a rule, less specific, compound H1 - 22px, purple, uppercase H2 – 18px, capitalize, burnt orange H3 – 16px, block.15 em letter space (space between the letters) Make a change, save a change Insert an image: add text for search engine purposes. Choose an img from the image folder. –Copy and paste img 2 more times. Double click the img and replace with any img. It saves the alt text. Create a div: select all, insert div tag: wrap around selection, wrapper. Make a rule (ID type) –Box: 900 W x 650 H –Margin 18px (1/4”), right & left auto –Border solid, 2px, (by default it is aligned to the center of the page) Reduce some of the text –* tag – universal tag, wild card, first tag. Box: padding 0, Margin 0. Anytime you see a blank box, it defaults to the parent div. * is the grandfather of all divs.. Talks to all of the other tags. Nothing selected + new rule P – paragraph tag for the entire site. (Box) margin Bottom 1.5 em space height of the letter.

4 Separate content into divs 1 st paragraph – select, name: header 2 nd paragraph – select, name: mainConent (camel case) Set the rules: Select the: header tag, make the rule. –Box: H150 – 20, padding 10 all, 900 W – 20 pad Img: Specific for header: remove p, (so now it says #header img ). Float to the left, margin 1.1em right. mainContent, rule –Box W for sitNav- 60 padding (690), H 650 – 150 for the header -60 for padding (440) –Padding: 30 px, -60 from the height., Float to the left even though the sitNav is not there yet. End 1/10/11 –Img tag – parent tag for the entire site –Float: left, margin 1.1 em on the right, which will look like the heading image tag for now 3 rd paragraph – sitNav has not been created yet. Click at the end of main content text, insert div tag “Before tag”,, or we could have chosen After tag, ID; sitNav. It will be between header and mainContent. Now make a rule. –Select: sitNav - Make the rule: Box, W (130), (480), padding 10, float left –Type: about, price, products, service, contact (enter between each) Go back to wrapper, add the color: white. If you have a background image it will cover it. Rearrange the CSS Right panel like the image

5 Float the mainContent image to the right by creating a class tag or custom tag Select the mainContent image. Select the tag, make the rule. Create a rule for the #maincontent img.rightimg The period makes it into a class. Classes are defined, then classes are assigned. Now we are to assign it to something. –(define) Box override the parent tag (the img tag), float to the right, margin to the Left 1.1em. Right 0. 0 is a value –(assign) Select the Class tag: rightimg. Now it moves to the right.

6 (P3) Make aesthetic changes to the div tags mainContent - remove some text to fit in space –Box: top add 10 to padding (40 total), subtract 10 from the height (430). Add 27 from the left, subtract 27 from the width (663) P tag rule for maincontent. Select the tag, make the rule #mainContent p –Line height 1.6em (more space between the paragraph lines) Create a rule specifically for the main content images. –Click 1 st img of maincontent, #mainContent img Border: solid, 2, pink. Right now both images have a pink border –Double click the class tag #mainContent img.rightimg to make a blue border. Change the color to blue. You do not have to put the style or width since it reads the parent tag #mainContent img –H2 inside of maincontnet, name #mainContent hr – Box, margin.6 em. Makes more space between the tags. Check the order of the tags. Links: select Paragraphs (about, price, etc), add unordered list. –Make hyperlinks: add # symbols to each. They behave like a hyperlink. –Select all of the items, create a rule for #sitNav ul: List, none. –Select tag, #sitnav ul li a, type: white, background purple, (apply – it’s in a line) Display: Block, Block category, Line height 30px, padding, left, 12 px, Box: margin: 12 (outside of the box) Hover tag –Select rule #sitenav ul li a:hover (type in from scratch) –Background > green. No other rules because a is the parent tag. An entire page with Rules, floats, div tags, class tags Clean up the CSS styles: move the rules in order of groups. _________________________________________________________________END

7 The Div Tag for Page Divisions Dividing the Page with the Tag The tag is used to establish separate divisions or areas of your page. It is one of the most powerful elements in xhtml, as it is essential for positioning the design of your page using CSS. The id Attribute (the name of the div) The id attribute can be used with any tag element, but to identify and define an area of your page, the tag can be used. Facts about id’s: The value for the id attribute must be used only once on your page. It is a unique identifier. The id value is case-sensitive. “Home" is different from “HOME" and also different from “home" – it is easiest to use all lower case letters. Do not use spaces or any special characters as the id value. You may use letters, digits (1 thru 9), dashes (-), and underscores (_) but you must start the id value with a letter.