Assignment 4: Cascading Style Sheets and Structure

Syllabus | Due Date |


Question 1: Linking to Cascading Style Sheets

Create a set of 3 identicial web pages that differ only in the way they applying CSS style to HTML content:

  1. First document: External style sheet
  2. Second document: Internal style sheet
  3. Third document: In-line style sheet

Source of Moby Dick text was Project Gutenberg


Question 2: Style Sheet Linking

What are the advantages and disadvantages of the three different ways to associate a CSS style to an HTML element?

External Style Sheet

Advantages
Can link to multiple documents
Disadvantages
Need to use consistent markup on multiple pages

Internal Style Sheet

Advantages
Manage styling within a single document
Disadvantages
Hard to maintain consistency across several related web pages

In-line Styling

Advantages
Can be useful for unique changes to a an elements stryling within a document
Disadvantages
Hard to maintain consistency across related elements

Question 3: Using CSS Styling and HTML text to create a button with similar graphical effects of the following image:

Button

Button