Archived copy for reference only
 

 

Graphic Design / Interactive Design / Fine & Applied Arts / Parkland College

Interactive Design Exercises
Web Design (Part 5 of 5): CSS and Javascript in Dreamweaver

Objective

To become more comfortable in the Dreamweaver environment by constructing a complete web site similar to this web site.

Also see the Advanced Web Mockup and Slicing for Web Production exercises.

Discussion

Just as in print, visually appealing web pages involve a balanced layout and clean typography. In this lesson, we'll pay particular attention to these issues.

Good web typography requires the use of Cascading Style Sheets (CSS). Using CSS, designers can control line spacing and precise font sizes with pixels. CSS can also remove the ugly underline for links that is the default for HTML. For more information on web typography, reference this excellent master course.

Procedure

Overview: Import optimized pixel elements into Dreamweaver, add DIVs. Create a CSS style sheet. Add JavaScript behaviors. Make a master page. Apply master page elements to content. Test, publish to server.

Creating the home page

  1. download starter files (move files to proper location)
  2. download CSS reset starter files (move CSS files to proper location)
  3. launch Dreamweaver
  4. define a new site (site > new site): name="dm css",
    local root folder=faa999/class/html/exercises/dm_css_html
  5. cloak assets folder (RMB > cloak)
  6. open "index.html"
  7. select all content, DELETE
  8. insert > layout objects > div tag (id=hcenter)
  9. insert > image: "home-logo.jpg" (inside <div#hcenter>)
  10. insert > image: "home-pix.jpg" (id=pix)
  11. open "home-links.html", copy and paste <table> into "index.html"
  12. window > css: link "reset.css"
  13. window > css: add new rules (+), define in this document only
    • body: background: color=black
    • hcenter: box: width=1024px, margin left/right=auto;
    block: text-align=center
    • #pix: box: margin-top=50px
    • .center: block: display=inline table
  14. select <table>: style=.center
  15. file > preview in browser (opt+F12 and cmd+F12)

Vertical centering

  1. select <body>: insert > layout objects > div tag
    (wraparound=yes, id=vcenter)
  2. window > css: add new rules (+), define in this document only
    • vcenter: positioning: absolute, T=50%;
    box: margin-top=-?? (half of height), width=100%

Finishing the HTML file

  1. change title to "Parkland College Digital Media"
  2. window > snippets: meta > no cache (insert in code view)
  3. add alt tags
  4. commands > clean up XHTML
  5. file > check page...

Creating the inside "master" page

  1. open "curriculum.html", save as "master.html"
  2. modify > page properties: tracing image="tracing.jpg" (50% opacity)
  3. select <body>; insert > layout objects > div tag (id=text)
  4. place cursor right after <body>
  5. insert > image "upperRight.jpg" (id=logo)
  6. place cursor right after <body>
  7. insert > layout objects > div tag (id=links)
  8. insert > image "links_01.jpg" (inside <div#links>)
  9. copy and paste image 4x (total of 5); swap out images (double-click)
  10. window > css: link "reset.css"
  11. window > css: add new rules (+), define in new file "layout.css"
    • #links: positioning: absolute, W=??, H=blank, T=??, L=??
    • #logo: box: float=right
    • #text: box: W=50%, margin-left=20%, margin-top=??
    • body: min-width=1024px
  12. add <br> after <img#logo>: class=clearFloat
  13. modify > page properties: delete tracing image
  14. file > preview in browser (opt+F12 and cmd+F12)
  15. window > css: edit <body> (double-click): bg=black

Adding font CSS styles

  1. window > css: link "font.css"
    • delete <h1> rule
    • rename #font as #text
  2. window > css: edit rules (double-click)
    • #text: color=??
    • <a>: color=??
  3. window > css: add new rules (+), define in new file "font.css"
    • #text td: padding-right=5px
    • <table p>: padding-bottom=.5em
    • <h3>: color=??; padding-bottom=1em
    • ".small": type size=.8em
  4. duplicate <h3> style, rename <h2>: text transform=uppercase;
    box: padding-top=36px, bottom=9px, margin-bottom=27px;
    border: bottom=1px solid, color=??;
  5. duplicate <h2> style, rename <h1>: font size=1.3em;
    block: letterspacing=.35em
  6. edit text, apply styles
  7. file > preview in browser (opt+F12 and cmd+F12)
  8. finish the HTML file (see above)

Making JavaScript rollovers

  1. select "link_01.jpg", add link
  2. window > behaviors: add "swap image" behavior,
    choose "link-over_01.jpg"
  3. repeat with other link files
  4. repeat with links in "index.html"
  5. add hotspot links to logo image (both "master.html" and "index.html")

Making the first inside page

  1. open "master.html"
  2. file > save as "curriculum.html" (overwrite)
  3. select "link_02.jpg"
  4. swap "link_02.jpg" with "link-hit_02.jpg" (double-click)
  5. remove link, remove javascript behavior
  6. save; close window

Applying the master page to other inside pages

  1. open "program.html"
  2. select all content, cut to clipboard
  3. close window
  4. open "master.html"
  5. select all text in <div#text>
  6. paste
  7. file > save as "program.html" (overwrite)
  8. select "link_01.jpg"
  9. swap "link_01.jpg" with "link-hit_01.jpg" (double-click)
  10. remove link, remove javascript behavior
  11. apply CSS class "small"
  12. save; close window
  13. repeat with other pages

Making gallery pages

  1. duplicate "layout.css", rename "layoutGallery.css"
  2. open "1.html", attach "reset.css", "fonts.css", "layoutGallery.css"
  3. edit "layoutGallery.css" styles:
    • <body>: box: margin top=25px; block: text-align=center
  4. repeat with other gallery pages

Grading

  1. publish entire site
  2. make a link from your process page to this assignment

BACK TO TOP
Last updated: 5/7/21