Web Tutorial - Simple
by Derek—2003.11.22 @ 2258
The more I design web sites for people, the more I have come to believe strongly in the mantra: "Feed a man a fish, you feed him for a day. Teach a man to fish, you feed him for life." I used to enjoy feeding "fish" to clients because they kept coming back for more. However, while I've been in graduate school I haven't had the time to spoon feed clients. Instead, I've been building "template" sites and providing tools to clients which allow them maintain the site themselves. I was trying to teach them how to fish.
This method has not been without its heart-ache, and there are times I still have to lead people in the right direction. I do, however, get very excited when a client "catches the vision" and discovers that they can do a lot of the maintenance themselves.
In an effort to provide more tools, tips, and solutions, I've created this note that presents a very simple web site "How-To".
How To
| If You Want To... |
Do This... |
| Create a link |
<a href="URL">
click here </a>
URL can
be a full
location ( http://www.mysite.com/path/to/page.html )
or a relative location to the page ( page.html ).
<a href="http://www.derekandmelissa.com/"> click
here </a>
|
| Make a link open a new window |
<a href="URL" target="_blank"> click
here </a>
Adding the target attribute to the link tells the
link to focus on a specific window. You can name
the target anything you like,
but _blank is a reserved word which will always
open a new window. If you name the target, you can
have new links always open in the same window, since it has
been named.
|
| Make a paragraph |
<p> Text surrounded by the "p" tag will be part of the paragraph </p>
|
| Create a "soft return" |
<br />
If you want to create a break, soft return, or new line in a paragraph, use the <br /> tag.
|
| Make a heading |
<h1> This is a
heading </h1>
There are seven different headings: h1, h2, h3, h4, and so
on. The largest heading is h1. Use headings to
create a heirarchy for your text.
|
| Embed an image |
<img alt="add a comment"
src="URL" />
URL can
be a full
location ( http://www.mysite.com/path/to/image.jpg )
or a relative location to the page ( image.jpg ).
<img alt="Photo of Derek" src="derek_face.jpg"
/>
You can use other attributes in addition to alt
and src for your images,
including width, height,
and border
<img alt="Photo of Derek" src="derek_face.jpg"
width="100" height="200" border="0"
/>
You should not need to specify the height and width of the
image if you scaled it to the correct size in your photo program.
|
| Make a bulleted list |
<ul>
<li>
Item One
</li>
<li>
Item Two
</li>
<li>
. . .
</li>
</ul>
<ul> stands for "Unordered List".
|
| Make a numbered list |
<ol>
<li> Item One </li>
<li> Item Two </li>
<li> . . . </li>
</ol>
<ol> stands for "Ordered List".
|
Web Images
| Topic |
Explanation |
| JPEG |
JPEG (pronounced "Jay-Peg") is an image commonly used on websites. JPEG images are best suited for photographs, or images with lots of gradiations of color. JPEG's compress the images, making the file size smaller for quick downloading. JPEG's can compress with different quality---the smaller you compress the image, the more distorted it appears. JPEG file names look like this: my_image.jpg |
| GIF |
GIF (pronounced like "GIFT") is a common web image format. GIF's are best for images with solid colors, like single-color logos. GIF's can also do simple animations. GIF's compress the image based on how many colors you use: more color means a larger file size. GIF file names look like this: my_image.gif |
| PNG |
PNG (pronoucned "PING") is a common web image. PNG's support transparency, letting you "see-through" the image into the background. PNG's support both photographic images and single-color images. PNG file names look like this: my_image.png
|
| RGB |
RGB is used in reference to a color spectrum. It is an acronym meaning Red, Green, and Blue. RGB is the color spectrum used in computer monitors and is an "Additive" color spectrum, meaning when you combine, or add, all three colors (red, green, and blue) you get white. RGB is the color mode used on web pages and web images (JPG, GIF, and PNG). When you create images for the web, make sure to save them in the RGB color spectrum.
|
| Image Resolution |
All images created for display on the web should be 72 dpi, or dots-per-inch.
|
| Image Dimensions |
One common mistake is to force a large picture into a small frame. This is done by taking a large image (e.g., 800x600) and "lying" to the browser by typing a false height and width (e.g., width="320" height="240"). When you create an image for the web, ALWAYS use the actual size of the image. If you need a smaller image, shrink the image in a photo program and resave it. When you force a big image into a small frame, you are still downloading the big image, even though it "looks" smaller.
|