 |
Typical questions visitors ask:

What are the concepts of making frames?
Picture this: You have just finished a nice afternoon of fishing. You have one big fish, one little fish, and a net. You could carry one fish at a time to your home (one in each hand), or nest them in your net.
In that little analogy, the fish represent two HTML pages and the net would be the page holding those together. In short, to make a frames page where two pages are shown, a total of three pages must be made.


How do I make frames with two columns/rows?
First, figure out if you want columns or rows of pages. In the source below, where you see "ROWS", change that to "COLS" if you want columns. Also note that "page1.html" and "page2.html" are the locations of the two pages to be framed. The "70,*" is the partitioning of the frames, where one is 70 pixles wide and the other takes up the rest of the screen.
HTML of Typical Two-Window Frameset Page |
<!DOCTYPE HTML PUBLIC "-//W3C/DTD HTML 3.2//EN">
<HTML><HEAD>
<TITLE>WELCOME!</TITLE></HEAD>
<FRAMESET ROWS="70,*">
<FRAME NAME="LINKS" SRC="page1.html" SCROLLING=NO NORESIZE>
<FRAME NAME="MAIN" SRC="page2.html" SCROLLING=YES>
</FRAMESET>
<NOFRAMES>Sorry, but your browser cannot support frames.
</NOFRAMES>
</HTML> |
HTML of Typical Three-Window Frameset Page (1 row on top, 2 columns below) |
<!DOCTYPE HTML PUBLIC "-//W3C/DTD HTML 3.2//EN">
<HTML><HEAD>
<TITLE>WELCOME!</TITLE></HEAD>
<FRAMESET ROWS="70,*">
<FRAME NAME="LINKS" SRC="page1.html" SCROLLING=NO NORESIZE>
<FRAMESET COLS="150,*">
<FRAME NAME="SIDE" SRC="page2a.html" SCROLLING=NO>
<FRAME NAME="MAIN" SRC="page2b.html" SCROLLING=YES>
</FRAMESET>
</FRAMESET>
<NOFRAMES>Sorry, but your browser cannot support frames.
</NOFRAMES>
</HTML> |


(Miscellaneous Frames Need-To-Knows)
Add these little tid-bits and get effects.
- Target links to the frames. In a link, add "TARGET=frame_name" in the first "A" tag. (see HTML Basics for more on links)
- Adjust margins. You can set how much space you want in the frames, at the edges of the pages themselves. Inside the "FRAME" tag with the page that you want adjusted, add "MARGINWIDTH=n MARGINHEIGHT=n" where "n" would be a certain number of pixels.
- The Star ("*"). When partitioning the page up into frames, you need to specify how much space is needed for each frame. A "*" would (in computer terms) leave any space leftover on the screen for the corresponding frame. Never write two stars when breaking up the space.
- Showing/Hiding Scrolls. In the desired frame tag, write "SCROLLING=YES" if you want that frame to scroll, and "SCROLLING=NO" if you do not.
- "Freezing" Frames. Keep visitors from resizing frames by writing "NORESIZE" in the FRAME tag of the desired frame.
- NOFRAMES tags. If a user has turned off the ability to use frames, then write <NOFRAMES></NOFRAMES> tags. Between them, write standard HTML code to be seen when frames are not.


How does one make "floating frames?"
Floating frames are for Microsoft Internet Explorer only. If you are using MSIE now, view an example at my Star Spangled Banner page. This kind of frameset is easier to make. It
could go directly on the index page, and it has the same look as a form text area. Just remember, the width and height written inside the "IFRAME" tag, should always be a slightly larger number than what is written inside the "FRAME" tag. I am not sure if this is really required, all I know is that if I do not do what I just mentioned, I get an error message.
HTML of Typical Single Window Floating Frame Page: (to go anywhere on any page) |
<IFRAME WIDTH=87% HEIGHT=65% SRC="page_in_frame.htm">
<FRAME WIDTH=86% HEIGHT=60% SRC="page_in_frame.htm">
</IFRAME>
|


(Netscape Specials)
There are some little extras that you could put in your frame tags to make them stand out in Netscape. They are:
- Changing the color of the border. Just add "bordercolor=
#rrggbb" where rrggbb is the hexadecimal equivalent of the color you
want (see: Color Tables), inside the first
"Frameset" tag.
- Adjusting thickness of borders. In the initial "Frameset" tag, write
"border=n", where "n" is the desired pixel width.
If you want no borders, you could set this to zero. . . though MSIE will
still show them.
Example: |
You want frames in rows with no scrolling on the top one, no resizing, with a border size of two (2), and a color of red. |
HTML: |
<FRAMESET ROWS="70,*" BORDER=2 BORDERCOLOR="FF0000">
<FRAME NAME="LINKS" SRC="page1.html" SCROLLING=NO NORESIZE>
<FRAME NAME="MAIN" SRC="page2.html" SCROLLING=YES>
</FRAMESET> |
---|


(Internet Explorer Specials)
There are some little extras that you could put in your frame tags to make
them stand out in MSIE. They are:
- Floating Frames.
- Adjusting spacing between frames. Within the first "frameset" tag, write
"framespacing=n", where "n" is the pixel size of the space. The space may show the contents of the Index page (any background,
images, or text you write on there).
Example: | You want frames in columns, and no borderspacing. |
HTML: |
<FRAMESET COLS="90,*" FRAMESPACING=0>
<FRAME NAME="LINKS" SRC="page1.html">
<FRAME NAME="MAIN" SRC="page2.html">
</FRAMESET> |
---|



page info © 2001, m. tartàglia
|