Getting images to fit without spaces
between them is necessary at times. You cannot put spaces or line
breaks in your code for this to be successful. Here are a few ways you
can do it:
<IMG
SRC='image.gif'><!--
--><IMG SRC='image.gif'>
OR
<IMG
SRC='image.gif'><IMG
SRC='image.gif'>
OR
<IMG
SRC='image.gif'><IMG SRC='image.gif'>
Frames
Frames may seem a bit more complicated
than the rest of HTML. I think the targets get a bit confusing,
so I'll give you a little help.
You can specify in which frame your pages show up by naming your own
frames. Also, there are a few target tags that are preset and very helpful.
These are:
<a
href="URL" target="_top">
--opens a new browser for the page
<a href="URL" target="_self"> --opens the page in
the frame it is called from
<a href="URL" target="_parent"> --opens the page
in the whole window in the present browser session.
You also do not have to specify the target in each href if you put the
tag <BASE TARGET="frame name"> This acts as a default
target, so you only need to specify if it is something different than
that.
If you want to get fancy, you can have rows and columns of frames.
For example, if you wanted them to look like this:
| Top Part |
Side
part |
Main
part |
you can make two
frames pages. It's like frames within frames. The first would define the
rows like this:
<FRAMESET
ROWS="35%,*">
<FRAME NAME="head" SRC="head.html" SCROLLING="AUTO">
<FRAME NAME="bottom" SRC="bottom.html" SCROLLING="AUTO">
</FRAMESET>
Then you would define
the columns in the bottom.html file like this:
<FRAMESET
COLS="20%,*">
<FRAME NAME="side" SRC="side.html" SCROLLING="AUTO">
<FRAME NAME="main" SRC="main.html" SCROLLING="AUTO">
</FRAMESET>
Javascript
There are lots of different
ways to make images change when the user goes rolls over them
with their mouse. I like to use the easiest one that fits right into
the image tag. Here's the code:
<A
HREF="page.html" onmouseover="nlogin.src='images/nlogin2.jpg'; onmouseout="nlogin.src='images/nlogin1.jpg'"><IMG
SRC="images/nlogin1.jpg" ALT="New Log-In" BORDER=0 ALIGN="TOP" NAME="nlogin"
WIDTH=130 HEIGHT=33></A>
If you'd like a little message to show up instead of the location
when the user's mouse travels over a link, you can put in a little extra
in the anchor tag. Here's an example:
<a href="page.html"
onMouseOver="window.status='Go here. You'll like it!'; return true">My
page</A>
File Stuff
To avoid having to always
rename your main page index.html or have people type in the file name
as part as a URL, you can create a soft link to the file. (Ex.
Say, the first page I want people to see when they visit http://www.mydomain.com/
is really named hi.html. Instead of having them type in http://www.mydomain.com/hi.html,
you can set hi.html to come up by just typing on http://www.mydomain.com.
Log into your
UNIX account, go into your public_html directory, and type ln
-s filename.html index.html at the command prompt.
Having the problems that you cannot view your web files even
though you swear you put them in the right place? Make sure that all
of your directories are executable and readable. To change the permissions
of the directories in UNIX, type chmod ugo+xr directoryname
at the command line.
Instead of having to go through a program or ftp from DOS (I'm a PC
girl), you can ftp files through dragging and dropping them into your
browser window. You do this by typing in a URL is this format in your
web browser: ftp://username:password@location.home.edu/directory/subdirectory/.
Then you go into your file manager/explorer window and drag the file
into the browser window.
META Tag (Push-like)
Do you ever wonder when
you get to those pages that reload for you a number of seconds
later? Well, you can do that by using a META tag:
<META
HTTP-EQUIV="refresh" CONTENT=1>
The number you put
after CONTENT is the number of seconds it will wait before refreshing
the screen. An annoying thing I found about this is that it doesn't stop!
Another neat extension to this is that you can reload a particular
page in a specifies number of seconds as well:
<META
HTTP-EQUIV="refresh" CONTENT="5; URL=http://www.page.com/">
If you had a
desire to bounce back and forth between pages every certain number of
seconds, you could use this tag to do so.
Warning: this only works with a Netscape browser as far as I know.
Audio
This META tag
can be used for starting up background sounds:
Not many people
do this, though. Another way to do it is:
The usual way of putting in sounds as a link that people can
click is as an anchor:
The following tag will work to put audio on your page as well.
It will start when the page is loaded. This tag also shows a little
player on the page and the audio is endless:
This one has
a hidden audio player:
Tags
The "em" dash
are the longer ones. To use them, I simply use two hyphens (--), but
I came across a different way. You make a single pixel black gif and
put this line in your HTML code:
I also just recently
found out that there is a special character code for this: —
This makes sense for all of the people who are used to using Alt-0151
in their favorite applications.
If you're sick of letting the browsers display the default font all
of the time, you can specify the font people see your pages with. You
do this by creating a list the desired fonts for viewing text.
To do this, use the tag:
The only trick
with this is that the user must have your specified font on their computer.
You may specify multiple fonts in the order of preference to increase
the probability that a person has one of them. Arial usually is a pretty
common one.
You can manipulate the HR tag to create a box using <HR SIZE=25
WIDTH=25>.
You can change the kind of bullets that are shown with the <LI>
tag: You use <LI TYPE=type_you_want> to achieve this. The different
options are: circle, disk, square, 1 (numbers), A (uppercase letters),
a (lowercase letters), I (uppercase Roman numerals), and i (lowercase
Roman numerals).
You can also specify the font color of individual words by using
the hex code or the word of the color.