|
8:30-8:45 / 1:00-1:15 |
Tables lecture (Trev) |
|
8:45-9:40 / 1:15-2:10 |
Tables practice |
|
9:40-10:00 / 2:10-2:30 |
Web Standards / XHTML rules lecture (Kass) |
|
10:00-10:30 / 2:30-3:00 |
Break |
|
10:30-11:00 / 3:00-3:30 |
CSS Basics lecture (Stevie & Vivian) |
|
11:00-11:30 / 3:30-4:00 |
Revising old pages and use CSS / Class log / Journal questions |
|
11:30-11:40 / 4:00-4:10 |
Introduce web services project / Sign-ups |
|
11:40-12:00 / 4:10-4:30 |
Free Time |
Tables
Tags:
<table></table> - Table - creates a table.
<tr></tr> Table Row - begins and ends a row.
<th></th> Table Head - typically used at top of table.
<td></td> Table Data - creates a cell.
Attributes (within the Table tag)
<table border="2" width="30px|60%" cellpadding="6" cellspacing="10">
Example of a basic 2x2 table:
<table border="1">
<tr>
<td>1A</td><td>1B</td>
</tr>
<tr>
<td>2A</td><td>2B</td>
</tr>
</table>
Standards Compliance
The three things you need in all of your HTML documents. (Note: you still give all your documents a .html extension, despite our use of the term XHTML.)
-
Add a "DOCTYPE" declaration to all your documents. A List Apart has a decent article with all of the doctypes you'll probably ever use for your projects. (Strict vs. Transitional)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -
Your beginning <html> tag shall henceforth look like this:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
-
And you must include the following tag within your <head> </head> section:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
XHTML rules (most of which you've already been doing!)
-
Tag contents should [almost] always be lowercase. Very few exceptions.
-
Tags that have attributes defined in them must have quotation marks, either a single or double.
-
All tags must have an accompanying closing tag.
-
Nest your tags properly: First In, Last Out as they say. (i.e. <b><i></i></b>, NOT <b><i></b></i>)
-
Do not use deprecated tags or attributes, or "out of date" tags. Check the book or Google to see if a tag is deprecated or just try it and see if your page validates.
All pages that you make must have a validation link on them for both HTML and CSS. It might look something like this:
<p><a href="http://validator.w3.org/check?uri=referer">XHTML 1.0</a>, <a href="http://jigsaw.w3.org/css-validator/check/referer">CSS 2.0</a></p>
Funny pic that Lloyd found for me: http://poisonedminds.com/comics/pm20060621.png
Journal Question
What do you think of the whole standards issue? When should you use CSS and when should you use XHTML when designing a webpage? Do you see a clear distinction or is a bit confusing to you right now? Also, how much of your previous web work was not XHTML standard-compliant?
Homework
-
Prepare for your website presentation. Those of you who got the more popular sites have to present on Monday!!
-
Make sure your indexes are updated for the week.
-
Finish making all your pages XHTML standard compliant and put validator links on each page to make sure.
-
If you want to learn more about tables, read pages 205-222 of chapter 13.