Designing Christian Web Sites


2 FRAME OR NOT 2 FRAME


TERMS

FRAMESET- States to the browser a frameset (set of frames) is starting here.

COLS- States to use columns (up and down).

ROWS- States to use rows (across).

FRAME SRC- (Frame Source) States where the Source (different) pages will come from. The first page will be to the left the second next to that, if you add a third it would be to the right and so on. When using rows the first will start at the top.

</FRAMESET>- States that the Frame is done.


First of all Frames will not work with some browsers.

You may want to use this code so you do not have to make 2 sets of pages, or have people not be able to see your page correctly.

<HTML>
<HEAD>
</HEAD>
<FRAMESET COLS="">

(This is what you are adding)
<NOFRAME>
Put a message here for people who can not see the frames. They will see this and follow this link instead.
<A HREF="http://address/">No Frames here? try this :)</A>
</NOFRAME>

<FRAME SRC="">
<FRAME SRC="">
</FRAMESET>
</HTML>


Second of all when working with frames the following code is very important, because once you get trapped in a frame, you are trapped.

TO BREAK OUT OF FRAMES:

<A HREF="http://address/The URL address you want them to go to" TARGET="_top"> CLICK HERE</A> to break out, if you are trapped in a frame.

CLICK HERE to break out, if you are trapped in a frame.
Click here now will just take you to the top of the page but if you were trapped in a frame, you would have just gotten out of it.


Third of all it will take more than one page to make frames. If you want to make a page with a frame to the left and a frame to the right you will actually need three pages. The main page will be the one people actually go to and the other two will show up on that page when they go there.

Example Page 1 Page 1 here
Example Page 2 page 2 here
Example Actual Page Now we have pages on one page.

Code for the actual page they will visit:

<HTML>

<FRAMESET COLS="50%,50%">
<FRAME SRC="pg1.html">
<FRAME SRC="pg2.html">
</FRAMESET>
</HTML>

Thats all there was to it. Quite simple. Now remember a fourth thing, you cannot put in a body tag on the page they will visit after the HEAD like you usually would or it will not work. But you can put your title and metta tags in the heading.

Notice in the code above
<FRAMESET COLS="50%,50%">
50% means that we will have both columns be 50% or half a page each. You want the numbers to equal 100%. We can adjust that by making it any size we want.
Look at 20% and 80%.


We can make more frames by adding more pages, and COLS numbers equaling 100%. Example Here

<HTML>
<FRAMESET COLS="20%,40%,40%">
<FRAME SRC="pg1.html">
<FRAME SRC="pg2.html">
<FRAME SRC="pg3.html">
</FRAMESET>
</HTML>


We chould make the frames into rows instead of columns.

<HTML>
<FRAMESET ROWS="33%,33%,34%">
<FRAME SRC="pg1.html">
<FRAME SRC="pg2.html">
<FRAME SRC="pg3.html">
</FRAMESET>
</HTML>

If you have not tried it already, click on one of the links in one of the frames. You will notice that you go to the next page but the next page is still only in that one frame. To break compleatly out of it use this code, on the link you wish to break out of.

<A HREF="http://ADDY HERE" TARGET="_TOP">

For an example Click here On the "Example page 1 here" find the link that says "TARGET TOP" and click on that.


Now let's say you want to make a list of links and then have an index in the left frame that will bring you other places in the right frame.

Original frame Where they visit:
<HTML>
<frameset cols=25%,75%>
<frame name="Left" src=IndexFramePage.html>
<frame name="Right" src=pg1.html> </frameset>
</HTML>

Contents Frame to the left:

<HTML>

<a href="pg1.html" target="Right">pg1</a>
<P>
<a href="pg2.html" target="Right">pg2</a>
<P>
<a href="pg3.html" target="Right">pg3</a>

</HTML>



Frames with no Frame Showing:

The main page people would visit.

<HTML>

<FRAMESET COLS="20%,80%" FRAMEBORDER="0" FRAMESPACING="0" BORDER="0">
<NOFRAMES>
</NOFRAMES>
<FRAME NAME="A" SRC="Addy Here" MARGINWIDTH="3" MARGINHEIGHT="10" SCROLLING="no">
<FRAME NAME="right" SRC="Addy Here" MARGINWIDTH="3" MARGINHEIGHT="10">
</frameset>
</HTML>

It is the same at the frame above except the frames do not show up.

If you make too many links and it goes down too far a frame scroll may show up. In some cases I have gone to pages with the scroll set to "no" and not be able to see all of the links too.


You can combine rows and columns:

</HEAD>
<FRAMESET COLS="50%,50%">
<FRAMESET ROWS="50%,50%">
<FRAME SRC="pg1.html">
<FRAME SRC="pg2.html">
</FRAMESET>
<FRAMESET ROWS="50%,50%">
<FRAME SRC="pg3.html">
<FRAME SRC="index.html">
</FRAMESET>
</FRAMESET>
</HTML>

You can change the % and have them be different sizes you can add more pages, and have more frames. There is all kinds of things you can do :)


You can add color to the frames:

<html>
<METTA TAGS HERE>
<title>Color in the Frames</title>
</HEAD>
<FRAMESET ROWS="33%,33%,33%" BORDERCOLOR="0047FA" noresize="yes">
<FRAME SRC="pg1.html">
<FRAME SRC="pg2.html">
<FRAME SRC="pg3.html">
</FRAMESET>
</body>
</html>


Just add bordercolor. You can change no resize="yes" to "no".


You can mix and match, practice putting things together and come up with different pages. That is the fun of HTML. Have an idea of what you want to show up and then start working with the HTML, to get it to do what you want.