The Frame Lab --

Learning to Use Frames Effectively

Table Of Contents:

   Pre Lab:
      Goals of the Lab:
      Introduction:
      Frames:
      How do frames work:
      The Tags of the Frame Page:
         The <Frameset></Frameset> container tags:
         The <Frame> tag:
         sThe <Noframe></Noframe> container tag:
      Targets:
      The <base> tag:
      Other tags with the a target attribute:
      Special Targets:
      Simple Examples of a frame page:
         The first example:
         Second Example:
      JavaScript and Targets:
         Example of a JavaScript Application involving frames:
   Adding Multi Media to Your Pages and Frames:
      Adding Background Audio to a Page
      Sound Resources for Your Web Pages:
      Adding Background images to your Page
      Test the colors and backgrounds to see if it works out:
      Using full width background tiles and tables as alternative to frame page layouts:
      An example of using a full width background:
      Now look at the following page layout:
      Tools for Generating Banners and other Useful Art Work for Your Page:
      Using the MS Word 2000 to create art work for your page:
         Sample logo images (.gif) creates using MS Word:
      Effective Frame Web Page Design:
      Issues that must be addressed when using Frames:
         Using a simple javascript can prevent you document from being load inside a frame page:
      See more of Dr. Shiran's JavaScript for solving frame problems:
      How to Design a Frame Page:
      Story Board the layout:
      Creating the Frames:
         Additional Reading material for those that are interested in web site design:
   Self Test of Lab Concepts:
   Example:
      Example Similar to Lab 6 Exercise
      Detailed Explanation of how the Table of Contents Works:
         JavaScript Applications Shown in the TOC:
         The image rollover:
         The Form Navigation Page Selector:
         The Page Color Changer:

   Lab Instructions -- The Creation and Effective Use of Frames:
      Exercise 1:
       Exercise 2: Create the Initial Frame Pages for the Frame Set
          Step 1: Create the Logo
         Step 2: Create the MainPage Initial Page
         Step 3: Create the Table of Contents Page
       Exercise 3: Testing and Validating the Frames
      Exercise 4: Modify your web home page, index.html; and transfer all files to your web site
   References:
      Glossary of New Terms:
      Related Tutorials:
      Tutorials on Design of Web Sites:
      FAQ's:
   Other References:
      Netscape's Manuals Library
Emai

Pre Lab:

This lab will begin to introduce the student designer to more complex  web design choices The basic concept is called a frame page. Think of the display window in the browser as a real window and think of the frame page as the physical support structure that defines the various display real estate into separate areas of display. Each separate display area is like the window's pane and is called a frame.

Goals of the Lab:

  1. To learn the concepts of a frame page and to become familiar with the various frame tags and their attributes.
  2. To explore the use of frame pages to provide a consistent and user friendly navigation process.
  3. To learn some simple tools for creating banners/logos and for adding sound and other multi media into the frame structure.
  4. To apply JavaScript that allow for the loading of HTML pages into specific frames and other JS applications for adding some sizzle to your site.
  5. To become familiar with the design principles involved in a frame page web site.

Introduction:

The frame  allows the designer to create a consistent method of navigation for larger sites. It also allows for the creation of the web site that has not only a consistent look and feel but one that keeps the companies banner or it sponsors advertising message  always present while the various pages are loading. This banner frame is sometimes called the splash page. The use of many multi media including audio are included in the assigned exercises. While many professional web site designers prefer to not use large amounts of multi media and images to avoid detracting from the main message, causing excessive download times, etc. In a real commercial site the use of these may be either encouraged or discouraged by corporate policy and consideration of the resulting bandwidth and load time available to the average user.

The issue of whether to use frames is also complex. The choice to not use frames is a matter more of preference and conservative design policies that arose during the mid-90s when the frame tag was less uniformly supported. The alternative is to use tables (see Lab 4) or to supply an alternative to the frame page design based on using the <noframe></noframe> container tag. The number of Internet Explorer 3.0 and early Netscape browsers now form an ever decreasing percentage of the market. The two major browsers are freeware; and each corporation is bringing out many new features to attract and develop loyalty to their new versions. The cost of supporting pages that support the older browsers is a major issue.  Fewer commercial designers are using a non frame strategy but one should examine the various designs out there in determining your own web design strategy. Frames with multi media glitz are often used in entertainment web sites and those targeted for younger viewers.

Frames:

The basic concept is that the web designer first must layout the division of the the window in terms of areas and assign each area a unique name.
These areas are called frames. The structure that creates them is a special type of HTML document called a frame page. The frame page looks like a HTML with one major difference. The HTML document has a HTML container which contains a <Head></Head> but no body container. Instead of a body container it has a <Frameset></Frameset> container which contains either <Frame> containers or nested <Frameset></Frameset> containers. In addition to the <Frameset></Frameset> container it is recommended that a <Noframes></Noframes> container be included.

The function of the <Noframes></Noframes> container is to allow for older browsers to be provided an optional document that will only appear in those browsers that do not support frames. While this number of older non frame browsers are decreasing, they are not an insignificant part of the market. Browsers that support the visually impaired are among those browsers that do not support  frames. As will be expanded in later discussion the <NoFrames> container can be used to also over come a number of issues that detract from using frames.

The <Frame> tag defines the properties of the window area that is be assigned. In addition it links the default HTML document that appears when the user links to the frame page.

Why use frames for a web site?

The use of frame pages in a web site is normally driven by: The frame page is a document that has no visible content, except to non frame browsers. It must be loaded first and layouts the frames which in turn define the documents that are to be loaded into them. Framesets that are nested further define the areas into sub areas that are assigned frames, etc. While this may sound like frames and tables are equivalent, they are not. Frames allow the web designer to decide not only how documents are linked through anchors, image maps, etc. but once the view has decided on what document to visit next the web designer must specify through the use of the target attribute where it will be placed: Thus the web designer has much more control over the juxtaposition of two or more documents.

The Tags of the Frame Page:

The <Frameset></Frameset> container tags:

 

Attributes of the <Frameset> </Frameset> Tag
Attribute with allowed values Comments
Cols= "n1, n2, ... nm A frame set defined as columns, i.e. divides the window into vertical pieces. A frame set is either divided in columns or rows but not both. Remember Frame sets can be nested. 
The values, n1, n2, ... n are either integer (in screen pixels) or as a per cent ages with % sign included. The "*" value indicated the remainder. 
The <Frame> tags contained are assigned the column widths according to there order.
Rows= "n1, n2, ... nm A frame set defined as rows, i.e. divides the window into horizontal pieces. See Cols attribute remarks.
Border= "Number" NS only -- "0" is used for no border
BorderColor= "#rr,gg,bb" NS only -- Color of surrounding border in standard r,g,b hex values.
Frameborder= "yes|no" IE only -- yes indicates a border

The <Frame> tag:

The frame is the area of the window defined in the <Frameset>. The frame is similar to the glass pane in a real window.
The frame tag defines:

Attribute of the <Frame></Frame> Tag
Attributes with allowed values Comments
Name= "String" The name of the frame -- it must be unique and is required
SRC= "URL" The default HTML page to be loaded into the frame any time the frame is initialized.
Scrolling= "yes|no|auto" The scroll bar: 
  • yes -- scroll bar is required 
  • no  -- no scroll bar. This should only be used if there is never a need for a scroll bar. Use very carefully
  • auto -- the computer decides if it is needed and creates one as needed. This Should Be the Default
NoResize Do not resize the frame as the window size changes.
Frameborder= "yes|no" Create a frame border
Bordercolor= "#rr,gg,bb" Create a border color where #rr,gg,bb is the HEX Color triplet.
Framespacing IE -- space around frame
Marginwidth= "N" N is the number of pixels of margin at the right and left end
Marginheight= "N" N is the number of pixels of margin at the top and bottom

The <Noframe></Noframe> container tag:

The <Noframe></Noframe> container is used to advise the reader that the document is designed for frame page and that the viewer's browser is not frames enabled. As a minimum is to offer the option of downloading a frames enabled browser like Netscape and provide a link to the download. However, this leaves the viewer who, does not want that option or some reason can not use the download -- lack of time, memory, etc. to go elsewhere. A better strategy is to offer a page that contains a site map with a navigational bar to the various sections or pages of the web site.
The inclusion of the navigational menu allows the viewer to navigate the site. More importantly gives the search engine a means to explore and catalogue the web site. This, of course, is not a minor matter for an E-commerce web site. Many search engines can not examine a web site with a frame without this menu. Further the frame page mst also include the <Meta> and <Title> tags that are appropriate to the site. Include in  the <NoFrames> container a good executive summary of the web site. This summary should contain an introduction that give sites key words, phrases, and concepts. This goes a long way in helping the search engine spider to correctly find the pages of the web site and to correctly catalogue them.

Targets:

The targets are those attributes in the tags of the body of pages that direct the linked HTML document with the correct frame. They are the traffic cops that work to get the information moved to the right final destination.
 

The <base> tag:

The most common choice is to use the <Base> tag to establish the default.
 

Use the <Base> tag to establish the default option for the target for linking
Insert the following code snippet into the Head of the document where the linkage occurs
:
In this code example we have our text links in the TOC and desire that the default behavior is that the linked document appear in the frame, "Main" 

          <Base target= "Main">. 
 

Click here to go to a simple example.

.
 


 

Caution  -- All Frame names are case sensitive
Failure to remember this can cause errors.

Failure to establish a default forces the designer to assign a target for every link!!

Other tags with the a target attribute:

 

Tags used inside the Body Container to link HTML documents that use a Target attribute
Target Attributes used with HTML tags Comments
<A> Anchor tags:
<A Href="URL" Target="Name_of_Frame">Text </A>
The Document specified by the URL is displayed in the frame specified by the target when the the Text in the link is clicked.
Example Code Snippet:
<A Href="anchor.html" target="_top">
Click for a new window</A>
Example display:
     Click for a new window
<Area> used with Client Side Image Maps: The target attribute associated with the <area> tag that defines the shape and location of the ho spot in the image causes the link, URL, to be displayed in the frame whose name= "Name_of_Frame".
Example Code Snippet:
Click the number two (2) and observe the a new window with a [Back] will appear.<br>
<!-- Click on two to go to a new window -->
<map NAME="target-menu">
<area SHAPE="RECT" HREF="back.html" target="_self" COORDS="100,0,200,49"> </map>
<img SRC="menu.gif" USEMAP="#target-menu" height=50 width=300>
Example display:
Click the number two (2) and observe the a new window with a [Back] will appear. 
<Form> directing document flow:

<Form Action="URL" target="Name_of_Frame">

The target attribute will cause the document in the URL to be displayed in the frame whose name="Name_of_Frame"
Example Code Snippet:
<Form action="form.html" target= "_blank">
<input type=submit name="target" value="Click for a new window" target="_blank">
</Form>
Example Display:

Special Targets:

In the use of target attribute to direct the display in a desired frame there are some special targets. These targets have reserved words or names that reflect their special function.
 

Reserved Target Names 
or
Magic Targets
Special Target Names Resulting Actions
_blank Loads a page in a new un-named window
_parent Loads in the parent Frameset (next one up). If no parent exits acts like "_self".
_self Loads in the same window as the anchor that was clicked. Useful to override the default defined in the <Base> tag.
_top Loads on the top, i.e. breaks out of the frame page. 

Simple Examples of a frame page:

The first example:

The basic frame page note the default in scroll bars is auto. Here the top frame is the Menu page. In this simple example it is the site's navigation bar. The bottom frame is where the content is dispplayed. We use in this example three pages that when the viewed selects a color from the menu causeds the display of a page in the color selected. We see the <Noframe></Noframe> container that supplies the instructions to the viewer using a non frames enabled browser.
 

A basic One Frame Set/Two Frame, Frame Page
The layout diagram for the frame page:
 

Menu
Main
 

 

Example:
 
 

Click Here to see the Frame page

The HTML Source code for the frame page:

<HTML> 
<Title>Simple frame</Title> 
</Head> 
<Frameset Rows="20%, * "> 
   <Frame Name="Menu" SRC="Menu.html"> 
    <Frame Name="Main" SRC="Red.html" > 
</Frameset> 
 <Noframe> 
Your instructions for those browsers that do not support frames.
</Noframe> 

</HTML>

Second Example:

In this slightly more complicated frame page we see a typical design that might be used by an e-commerce site.   Frame set first set divides the areas into two rows. The first row is made up of a single frame named banner. Its function is to continuously display the corporate logo or advertisements. The second row has a nested frame set that divides the area into two columns. The left one is used for a navigational bar which we have labeled the TallMenu and the right one is the Main where the pages (such as a catalog of products) are displayed. Note the absence of the body tag container. We see the <Noframe></Noframe> container that supplies the instructions to the viewer using a non frames enabled browser.
 

A Nested Frame Set, Frame Page

Banner
Menu
 

  Main 
 
 

 

<HTML> 
<Head> 
<Title>Simple frame</Title> 
</Head> 
<Frameset Rows="20%, * "> 
   <Frame Name="Banner" SRC="Red.html"> 
    <Frameset Cols= "20%, * "> 
        <Frame Name="TallMenu"      SRC="TallMenu.html"> 
        <Frame Name= "Main" SRC="Red.html"> 
    </Frameset> 
</Frameset> 
<Noframe> 
Your instructions for those browsers that do not support frames.
</Noframe> 
</HTML>
Click Here to see the Frame page

JavaScript and Targets:

The think to remember in the JavaScript is that the object structure is based around the container. The frame is inside the parent frame set thus the dot notation for the designation of anything inside the frame container is:
 

Dot notation for Specifying Frame Attributes or Methods
parent.Frame_name.Attribute_name

parent.Frame_name.Method()

Example of a JavaScript Application involving frames:

Update of two or more frames at one time:

We will use the Javascript event handler, onClick. When the event happens we will load the frames with the new documents. The loading is accomplished by setting each frame to be updated with a new location attribute. Setting the location attribute causes it to load in the new document located the URL.
 
 


Three frame update 
(note not only the color change but the text does as well)
In each TallMenu(Red | White| Blue).html the following HTML tags has been added one for each color. (Shown here for changing to all red documents.)  
<A Href= "red.html" target= "Main" 
onClick= "Javascript: parent.Banner.location='Red.html;
               parent.TallMenu/location='TallMenuRed.html';
               parent.Main.location=      'Red.html';">
ALL red frames</A>
Click to see the Second Example modified to change all three frames at the same time. 
 JS3Change.html

Adding Multi Media to Your Pages and Frames:

Adding Background Audio to a Page

Before attempting to add background audio to a page the student should read the following:  After Reading the above material what we would do is to add both an <embed> and a <bgsound> to our page so the two most used browsers could carry out our selection.
For instance using hail.wav as our music we would:

<embed SRC="http://www.cs.uml.edu/~pkrolak/lab6/hail.wav" autostart="true" loop="true" width=200 height=55>
<bgsound SRC="http://www.cs.uml.edu/~pkrolak/lab6/hail.wav" Loop="50">
To get rid of the player controls add the attribute Hidden= true to both tags.
 

Sound Resources for Your Web Pages:

A page full of Sound Resources from Fortress Design.-- http://www.fortressdesign.com/resources.html

Adding Background images to your Page

In Composer 4.0

Test the colors and backgrounds to see if it works out:

Sessions Online School of Design's Color Calculator  is a good site to become familiar with to test your color concepts and background texture maps for readablity, harmony, and appearance.

Go to Sessions.edu .See:  http://www.sessions.edu/ilu/#  Please note the efficient and effective use of space. The results are gained by the clever use of Flash 5.0 and JavaScript.

Using full width background tiles and tables as alternative to frame page layouts:

Full width background tiles (an image that is designed to be the width of a page). Remember that a background is an  image or a texture used like tiles to cover the surface of the page. For the purpose of creating a layout that is naturally divided into vertical  regions it is best to select a tile that is wide enough to cover the width of the page (approximately 1350 pixels) and which has a pattern or bar of color on the left end and remainder some light color or texture. Such a tile is useful in setting up a narrow vertical bar of color or texture and a larger plain area. This is a frequently used technique by web designers to avoid using the frame tag and frame page for layout. They use a table tag to create a large table that includes the whole page. This large table is set up so the first column is over the vertical bar, this column is then reserved for the menu, or table of contents, i.e. a  navigational vertical button bar. The larger area to the left of this first column is reserved for the banner ads and navigation aids on top and the document's information below. Both of these to major columns maybe further broken down into table cells as dictated by the layout of graphics and content to achieve the designer's vision of the page layout.

An example of using a full width background:

Consider the following tile.

From images by John Sklar

Now look at the following page layout:

See --  The Great Web Site!
An example using a table to control the layout with the above full width background. While this is a rather simple example it does illustrate the point.

Tools for Generating Banners and other Useful Art Work for Your Page:

Web based tools for creating banners, logos, and other art work:

For Example the Logo Below was created with:
the Lazy Dog Font and [Effects] Drop Shadow

Other Useful Web Banner sites:

Flamingtext.com:

This web site supplies an impressivev array of web services for creating customized banners (headings), buttons, bullets, fonts, etc.
http://www.flamingtext.com/

http://www.guistuff.com/

Guistuff.com supplies a very useful service in creating a GUI template for you site including navigation.
 http://www.guistuff.com/

Using Shareware for creating attractive banners:

Using the MS Word 2000 to create art work for your page:

It is recommended that if you are using the HTML features of MS Word that the current version found in Office 2000 or later versions be used for best results. The creation of a logo can be quite time consuming and require the services of professional web designer for use in a large E-commerce site. However, it is possible to create attractive and very acceptable logo's using the tools built in the major word processor packages. Later we will look at the image editors and web graphic tools that allow even an amateur to create attractive and professional looking results. For a simple exercise let us consider the following: hypthetical situation. The client has chosen a background color scheme based around Kelly green a logo that states -- The Great Web Site! Wants the concept to be a real eye grabber. You feeling like Filbert return to cubical.

After meeting with a client go to your computer and open MS Word 2000.
To see what can be accomplished in a short time you:

Open a new page

Reset Page setup:
Move the
[Insert] object
SaveAs the document as  logo.html:
See a simple MS Word created logo.html

Sample logo images (.gif) creates using MS Word:

logo created with MS Word 2000 WordArt
MS Word 2000 & WordArt Logo

Effective Frame Web Page Design:

Issues that must be addressed when using Frames:

Frames while a powerful layout option is not without its problems. The designer must address the following problems.

Many Search engines do not handle Frame pages:

See remarks in the <Noframe></Noframe> discussion.

Web pages other than the home page maybe found by a search engine:

There are to ways to deal with this improtant issue.

The front door and the frame page must then both be registered with the various search engines.

Bookmarking a specific document in a frame and not the frame page:

The bookmark process marks the location of the frame page and not the specific page in the frame. If this of concern to your design use a trick like the site http://www.ask.com/ the meta search engine, Ask Jeeves. If you will examine the site closely you will see that the banner at the top of the page has a tab, Remove Frame. When Clicked it removes the page from the frame that it is in and places it into the "_top" window.. At that point the actual location of the HTML document in the prior frame is exposed -- look in the Location window of the browser and you will see the URL. The bookmark process will then work satisfactorily.

Perhaps an even easier way is to:

  1. place your mouse in an open area of the frame that you want to bookmark,
  2. click the Right Mouse Button and a pop up menu will appear.
  3. chose the option -- Open frame in new window,
  4. the frame will appear in a new window -- bookmark in the normal fashion.
Note this proceedure will also work for printing or saving the frame as well. The frame, actually the document in the frame, will now correctly bookmarked and its URL is in the Location window. One issue is that the frame will appear out side of the framepage that it was designed to be viewed with. This may not give the information as the designer envisioned it and may lead to some problems when you revisit the document.

Printing the [Print] button and using the [File]/edit page may produce wrong or confusing results:

One needs to be careful when using frame pages as it becomes necessary for the viewer to understand the concept of a frame and a page. If the designer is very skillful the frames may appear seamless and the user may not even recognize that it a frame page. Why is this important after all this was the effect the designer sought? If viewing and interacting with the window were the only process that viewer undertakes then all is fine. However, the minute the viewer tries to save the "page", edit the "page", or print the "page", etc. potential for confusion and frustration exists. The browser will normally print the frame instead of the "page", i.e. the window. Where did the information on the corporation go? The viewer may wonder I wanted the corporate phone number for my records. Here the printer knows from about window but assumes that you want the document where cursor is positioned last. This is no problem to the frame savvy user. It is the same thing that happens to the newbie when they print a black background document with with text and get a blank page. Similarly the act of saving the "page" if the novice is not careful what is saved is the "frame page" which is not the wonderful recipe or information the user thought they were storing. Not much can be done here. The viewer normally starts going to a newsgroup to report proof of alien behavior and is quietly informed about frames.

There is another approach to the above that deserves the reader's attention:
See Yahudi Shiran, Ph D. "Printing Frames",  http://webreference.com/js/tips/991123.html

The frame page may be used in a small window or have too many or two small a frame size to display the desired material:

The classic mistake about frames is to create page with too many, or too small, too crowded for some screen resolutions. The only way to avoid this mistake is to employee a design process that begins with a layout on paper of the window, a story board of user actions and navigational behavior, and testing of multiple combinations of operating systems, browsers, and screen resolutions. With the advent of WebTV the author must consider the standard video format. Some advocate only designing for that single format. This would seem to be too extreme but certainly it will be an issue to be addressed in any well designed and layout web site.

Using a simple javascript can prevent you document from being load inside a frame page:

One designs a page to be loaded into a user's window. But it sometimes happens that the user attempts to load it into some else's frame. This may lead to very undesirable results. To prevent this from happening the following simple JavaScript:
 

Prevent your page from being framed
Place the following script in the <head></head> Container:

<SCRIPT LANGUAGE="JavaScript"> 
<!-- 
if (window != top) top.location.href = location.href; 
// --> 
</SCRIPT>

Yehuda Shiran, Ph. D. , Escaping Frames, http://webreference.com/js/tips/000404.html  appeared as Tip of the Day 4/4/00

See more of Dr. Shiran's JavaScript for solving frame problems:

Doc JavaScript's Tip of the Day Archive, Frames July 29,2000 http://webreference.com/js/tips/browse.html?cat=000729

Navigation techniques for the web site:

The design of any web site must consider how the typical viewer will want to move through it. The process of moving from one page to another is called navigation of the site. In some complex large corporate web site we may actually be moving through pages from several sites (servers). The designer must decide what are the mostly uses of the site and facilitate the user's navigational needs based on these requirements.

Introduction:

The printed book is typically read from front to back going from page 1 to 2 ... until the book is read. This is called linear navigation. But not every book is read in that fashion. Consider the dictionary. Very few people read it by reading every word entry starting with the word "a" and going through to the z words. Most uses of the dictionary are random. We discover a word that we do not recognize and go to the dictionary and open it the pages with words starting with the first letter of our unknown word. We then may split the section in half and see if the word is in the first half of the section, repeating the process until we find the page. Thus we navigate the dictionary differently from a novel. Web sites can be organized like a novel with each page designed to follow the one in front of it. In which case we would find the site with a simple navigation design of a navigation bar that has perhaps three choices (next, back, and home or starting page). For a very small site (number of web pages) this is fine. But as the site grows larger it becomes cumbersome. If it is a large site, how do we find where we left off reading? Later when we go back to find specific material how do we find it?

In the dictionary example, the book is broken into smaller units by labeling the first page of words starting with a single letter. Larger text books break the material into chapters, lessons, or some similar grouping for similar reasons. For a  large web site with similar types of material we would create an "index page" with a navigational bar with links to the first page of each chapter. Each page in the chapter would have a link to the next, previous, and index page. Here what we are calling an index page is more like the Table of Contents that tells where each chapter starts. An index is a collection of keywords and phrases arranged alphabetically with the page(s) that address this concept listed beside it.

This form of index is very useful in text and refenece books where the reader reads and rereads the content and has to find specific passages for review or citation. A very large web site used for reference, help, or random access such as to a online catalog, can achive the same results as index by using a database and search engine to locate pages that deal with the keyword or concept.

Finally we may have many types of viewers some will read the pages from cover to cover, others will want a single page via a keyword search, others will be interested in sections of material. Thus we can expect that naviagation will often reflect a variety of navagitional appraoches to service the multiple type of viewer's and their needs.

Alternative mechanisms for creating user friendly navaigation:

 Similarly we saw that one of the most frequesnt applications of the image map was to create button bars for simple navigation tasks like (next, previous, home). In the prior material we have learned that forms and JavaScript allow for interaction between the user and the web server. Using forms and JavaScript will allow us to design a variety of approaches to complex navigational mechanisms. In a few cases we will select the navigational tools to allow better Computer Human Interfaces (CHI). These include buttons that flash when the mosue is placed over the choice or make a noise. The reader is reminded that design requirement and style should dictate which tool to use where. To much glitter will distract the customer and lead to sites that are confusing to navigate.

Simplicity -- the Navigation Bar:

The simplist navigational techique is the navigation bar (nav bar) -- that is a list of links in a single horizontal or vertical line. The best practice dictates using one at the top or bottom of the page. If a button bar or image map is used at either the top or left of the page an alternative nav bar is place at the bottom of the page to allow for a backup form of navigation in case the browser does not support the JavaScript or other devices required.

In the case where the web site employes a frame page as in the first example, we used the menu frame to hold the nav bar. See Frame page   where we use a horizintal list of links in the menu.

Menus featuring Roll over Buttons:

A roll over is a button/image map that changes its state when the mouse is passed over it. Normally, we use the event handler onMouseOver or onMouseOut which will call a JAvaScript function that changes the image in some manner, e.g.. makes the image turn red when the mouse is over it and green when it goes off it. Before the event handler is called we preload the two images (On, Off) so that the change of state is rapid and does not wait for the new image to be loaded from the server. This is accomplished by adding a JavaScript to the <head></head> container. Remember that the scripts in the head are activated (parsed) while the page is loading. The following is an example of a simple rollover nav bar.

For an example of a rollover nav bar. Place you mouse over the text in the logo::  http://www.kkrolak.org/
 

Alternative JavaScript Techniques that are simple to Create with great results:

The following site uses a Mouse Rollover and layers to highlight the text link,
WSAbstract.com, Creating onMouseover menu effects using JavaScript, http://www.wsabstract.com/javatutors/crossmenu3.shtml

Adding Sound to the Roll Over Button:

Sound is very effective in cueing the viewer that a button is being rolled over or clicked. The technique will help the vision impaired and if not over done set the site off from its competitos. For more on this subject see http://www.cs.uml.edu/~pkrolak/lab10/lab10.html

Tool for creating roll over buttons for both image and sound:

Hierarchial Menus -- based in Dynamic HTML:

The concept of a menu tree similar to Window's directory tree is another attractive and eye catching method of naviagating a medium to large web site. See for example the course's site could be laid out as follows: The javascript, NosTree a folding tree menu  is by  Sergey Nosenko, grab the script at: For those who want to impliment their site's navigation using this concept, it is strongly suggested that to visit the site

Pop Up Menus:

Alternative Software to Create your own Menu:

This is a tool for rapidly creating Menus for nav bars and other applications.
The Menu Factory by HTML Hut,  http://www.jwp.bc.ca/saulm/html/fac.htm

Using Search Engines:

One strategies used by large web sites is not to have a rigid navigation structure but to allow the user to it like a web search engine. Form a query to a database that either finds the stored page or generates it dynamically. Catalogues, archival sites like online news magazines (e-zines) aften use this technique for all or part of their sites naviagtion.

How to Design a Frame Page:

Frames deserve serious consideration as a technique for page layout particularly with a large site and/or complex navigation. However they do involve a more careful design before one begins to implement a frame layout than required ofr other design alternatives such as tables. The designer should:

Story Board the layout:

Lay the frame page out by first drawing the page on a graph paper and see  how a typical page will look. Try a simple mock up of the individual frames. Examine it with a variety of options such as no borders, no resize, etc. Let the window be a variety of sizes and repeat the previous exercise with the best candidates. Once the frame pages architecture has been resolved, we are ready to move on to the tough stuff.

Place yourself in the user's mind and imagine how the user will navigate the system. Layout the major portions of the site on a large piece of paper or tape sample pages to a white board. The drawn links to the way you envision the viewer navigating the site. Image that the user is dropped into an arbitrary page by a search engine -- What do you want the viewer to do after they have visited that page. This leads most designers to use tricks like that discussed in the section on JavaScript and Targets. A technique that is often employed is to place a navigational bar at the bottom of the page to lead the viewer to the site map or master frame page. If the page is difficult to understand without the supporting frame page them use the JavaScript in Forcing a frame into its designed frame page.

Creating the Frames:

Now that the planning and design is over and only then can one undertake to be gin the implementation of this page content. In general after the planning has been done only the frame page and the Table Of Contents (TOC) page will be outside of the normal web page creation done with Composer or other available page design tools. The frame page because it has normally no visible content is not done on a WYSIWYG web editor but something like MS WordPad. Composer does have a simple plugin to support the creation of a frame page.

As we shall see in the exercises the creation of the TOC can involve some HTML tags that are not support by the tool bar, e.g. the <Base> tag. We can overcome this by the use of the [Insert]/HTML tag ..  The failure to use the <Base> tag will lead the linking of the document into the TOC..
 

Additional Reading material for those that are interested in web site design:

General Design Issues -- Desk Top Publishing of Australia http://www.dtp-aus.com/typo/prnc-des.shtml
Best Sellers -- Web Design with Remarks,  http://eboz.com/shopping/book_store/best_sellers_design.shtml
Frames versus Tables: Comments from a newsgroup,  http://pages.whowhere.lycos.com/games/tiras/wsd01.html
 
 

Self Test of Lab Concepts:

 


Website Abstraction's Pop Quiz JS
CS 91 113 Using Frames Effectively
by P. D. Krolak & M. S. Krolak
Solution:
Your response: 
Start Over Cheat Mode

Example:

Example Similar to Lab 6 Exercise

Detailed Explanation of how the Table of Contents Works:

JavaScript Applications Shown in the TOC:

The image rollover:

The Form Navigation Page Selector:

The Page Color Changer:

See Also: "Image Map Lab Example",   http://www.cs.uml.edu/~pkrolak/CSimagemap/Frame.html
 

Lab Instructions -- The Creation and Effective Use of Frames:

For this exercise we will: Before attempting the exercises the reader should review and create a print out of the Design Resource Page:  http://www.cs.uml.edu/~pkrolak/lab6/DesignResources.html

Exercise 1:

Exercise 2: Create the Initial Frame Pages for the Frame Set

Step 1: Create the Logo

The first page, logo.html, will have a logo for the student's page of the own design.

Step 2: Create the MainPage Initial Page

The Second page, blank.html, will have no text only a background image of the student's choice.
The background image is added according to directions above.

Step 3: Create the Table of Contents Page

The third page, tocstudent.html,  open in Composer [new] page, [Blank Page] and modified as follows:
At the very top of the page, click on [Insert]/HTML Tag .
A dialog window will appear: This will cause the clicking on a hot link in the TOC frame to be displayed in the MainPage frame as the default. The return link is an example of overriding this default.
  • Add Links to:

  • Now you have finished the Table of Contents!!

    Save_as --  tocstudent.html



    For those who like a flashier web site
    Use the following alternative instead of the above :
     

    Exercise 3: Testing and Validating the Frames

    Once the three web pages have been created, you are ready to test the frame. Use the Navigator browser. Click [File]/open to select the framepage.html. You should see a window:

    Exercise 4: Modify your web home page, index.html; and transfer all files to your web site

    What to upload to your web site:

    References:

    Glossary of New Terms:

    Frames -- the <frame> tag container defines the area of the window that will have that name. It will also define the default HTML document that will occupy the window.

    Frame page -- the HTML document that defines the frames into which the documents will be posted. The frame page defines the hierarchy of frames and frameset containers. The frame page must have at least one <frameset></framest> container and one or more frames and <frameset></frameset> nested containers. The frame page has a head but no Body. A frame page should have a <noframes></noframes> container to handle those browsers that do not support frames.

    Navigation Bar or Nav bar -- A list of links to various key web pages in a site. The nav bar allows the user to navigate the site. This same function can be accomplished by button bars, more general image maps, hierarchial menus, pop up menus, or key word searchs.

    Navigate a site -- the process used by the viewer to visit the pages of a web site. Depending on the users' navigational profiles and the size of the site the designer must find an appropraite strategy to facilitate them.

    Story board -- The practice of using a white board or similar device to layout the design and connect the pages to see how the user will navigate the site. The story board is used in many different areas of presentation and graphics to see the physical relationship and flow of concept and images.

    Target -- the attribute of the tag that contains the name of the frame where the linked document is to be displayed.

    Related Tutorials:

    Tutorials on Design of Web Sites:

    General Design Issues --Desk Top Publishing of Australia  http://www.dtp-aus.com/typo/prnc-des.shtml
    Best Sellers -- Web Design with Remarks,  http://eboz.com/shopping/book_store/best_sellers_design.shtml
    Frames versus Tables: Comments from a newsgroup,  http://pages.whowhere.lycos.com/games/tiras/wsd01.html
    Tutorials on Web Design -- from Fortress Design  http://www.fortressdesign.com/tutorials.html

    FAQ's:

    Other References:

    Netscape's Manuals Library

    Dynamic HTML in Netscape's Communicator



     
     

    ©P.D.Krolak & M.S.Krolak 2000-3 All Rights Reserved

    Email