Home arrow HTML arrow Frames and Lists in HTML
HTML

Frames and Lists in HTML


In our previous article we learned to work with links and entities (or special characters) in HTML and how HTML handles white space. In this episode we will discuss how to use frames to create pages within the page and how to use lists.

Author Info:
By: James Payne
Rating: 5 stars5 stars5 stars5 stars5 stars / 9
January 23, 2008
TABLE OF CONTENTS:
  1. · Frames and Lists in HTML
  2. · Setting a Frame in the Horizontal Position
  3. · Displaying Frame with the Iframe
  4. · Lists in HTML
  5. · The Unordered List
  6. · Working with Nested Lists

print this article
SEARCH DEVARTICLES

Frames and Lists in HTML
(Page 1 of 6 )

Working with Frames

You can use frames to display more than one page in a browser window. This is useful for a variety of things, particularly if you want to create a menu bar across your website without having to program it or copy and paste it over every page. For instance, you can set your menu bar in a frame on the left side of the page, and when the user clicks on a link, the page will load in the center of the page (to the right of the menu bar frame).

There are four places to set your frames in an HTML page. You can set them vertically, horizontally, a mixture of the two, or inline, which we will discuss in a few moments.

Setting a Frame in the Vertical Position

Framesets use column and rows to determine where a frame is located. To set the frame vertically, we use the cols property:


<html>


<frameset cols="20%,80%">


<frame src="menuframe.htm">

<frame src="main_frame.htm">

</frameset>


</html>

The above sample creates two frames in the vertical position. It does this using the line: <frameset cols=20%,80%>. The word cols stands for column, and decides where the frame will appear (vertically for cols) and the 20%,80% decided the amount of the page the frame will take up. For instance, in this case we have two frames. The first frame (and the page nestled within it) will take up 20% of the browser. The second frame (and once again, the page within it) will take up the remaining 80% of the browser.

Next, we use the <frame src> to tell the browser which page to insert into the frame.


blog comments powered by Disqus
HTML ARTICLES

- Does HTML5 Need a Main Element?
- Revisiting the HTML5 vs. Native Debate
- HTML5: Not for Phone Apps?
- HTML5 or Native?
- Job Hunting? Freelancer.com Lists This Quart...
- HTML5 in the News
- Report: HTML5 Mobile Performance Lags
- The Top HTML5 Audio Players
- Top HTML5 Video Tutorials
- HTML5: Reasons to Learn and Use It
- More of the Top Tutorials for HTML5 Forms
- MobileAppWizard Releases HTML5 App Builder
- HTML5 Boilerplate: Working with jQuery and M...
- HTML5 Boilerplate Introduction
- New API Platform for HTML5

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 

Developer Shed Affiliates

 




© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials