.gif
and JPEG files end
with .jpg
. For now, don't worry about the difference.
NOTE: There have been efforts to add other graphics file types to the above two, but at this time you can't rely on these being supported by all of the currently popular browsers. |
<IMG SRC="new.gif">
<IMG>
tag always has to have the SRC
attribute included, since
that's the part that tells the browser what file to insert at
that point. If you have problems displaying your page, make sure
you included both the starting and ending quotes around the
filename; it won't work if one or both are missing. Also,
remember that when you use an attribute it always has to have a
space separating it from anything (such as the name of the tag)
that precedes it.
<BR>
tag before or after it to cause one or more line breaks.
<IMG>
tag as with an ordinary
graphic file and it will "play" whenever the page is loaded.
Try inserting the tag
<IMG SRC="ryoko_an.gif">
into your page and watch the results. (This
assumes you copied all the graphics to your hard disk as suggested above.)
BACKGROUND="[a filename]"
in the <BODY>
tag in your document. For example, to include the
file "chalk.jpg" in your page as a background, your <BODY>
tag
should look like this:<BODY BACKGROUND="chalk.jpg">
<BODY>
tag,
like this:
<BODY BGCOLOR="AQUA">
<BODY>
tag
at a time in your document (plus the </BODY>
tag at the end, of
course).
Example 2
shows you what this would look like.
AQUA | BLACK | BLUE | FUCHSIA | GRAY | GREEN | LIME | MAROON |
NAVY | OLIVE | PURPLE | RED | SILVER | TEAL | WHITE | YELLOW |
Terms to know from this lesson |
<IMG> ("image") tag: Inserts a graphic file into
the page at the location of the tag. |
SRC attribute: Tells the browser what image file to use for
the current <IMG> tag. |
BACKGROUND attribute: Tells the browser what image file to use as
a background (used in the <BODY> tag and other tags as well). |
BGCOLOR attribute: Tells the browser what solid color to use as
a background (used in the <BODY> tag and other tags as well). |
GIF file: A Graphics Interchange Format graphic file;
will have an extension of .gif . |
JPEG file: A Joint Photographic Experts Group graphic file;
will have an extension of .jpg . |
Animated GIF file: A GIF file which contains two or more images which will automatically cycle when the page is reloaded, creating motion. |
![]() | ![]() | ![]() | ![]() | ![]() |
![]() | ![]() | ![]() | ![]() | |