Solved

footer positioning?

Posted on 2002-05-10
6
248 Views
Last Modified: 2010-04-09
Hello

I have some pages that I want to have a common footer - which is a table that has a thin rectangle gif, and a back, top, and home buttons in it.
I'd like it to display at the "bottom" of the page as consistently as possible, preferably regardless of screen resolution, or how the window is resized.
How can I do that?

thanks

v
0
Comment
Question by:vlg
6 Comments
 
LVL 18

Expert Comment

by:bruno
ID: 7001878
use server side includes if you can, and just put it at the bottom of the page...
0
 

Author Comment

by:vlg
ID: 7001885
How does one server side include something, and what specifically would I have to server side include to make it go to the bottom?

v
0
 
LVL 17

Expert Comment

by:dorward
ID: 7002222
See the "faking position: fixed" for IE6 item: http://home.deds.nl/~thebox/ghost/index.html

You will probably want a fixed horizontal bar.
0
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 100 total points
ID: 7003213
I think what you need will go something like this:

The stuff you want at the bottom has to be in a layer (absolutely
positioned div for compatibility) like this:
<div id="thediv" style="position:absolute;top:0;left:0;visibility:hidden">

The do the body tag this way:

<body onLoad="positionit()">

This goes in the head:

<script language="JavaScript">
<!--
   var obj;
   var H;
   var divH;
   var T;

   function positionit()
   {
      if (document.all)
      {
         obj=document.all['thediv'];
         H=document.body.clientHeight;
         divH=obj.clientHeight;
      }
      else
      {
         if (document.layers)
         {
            obj=document.layers['thediv'];
            H=window.innerHeight;
            divH=obj.documentHeight;
         }
         else
         {
            obj=document.getElementById('thediv');
            H=window.innerHeight;
            divH=obj.offsetHeight;
         }
      }
      T=H-divH;
      if (NS4)
      {
         obj.top=T;
         obj.visibility="visible";
      }
      else
      {
         obj.style.top=T;
         obj.style.visibility="visible";
      }
    }
//-->
</script>

I don't have time to play with it, but it should be pretty close.  Might
need some adjustments for margins and such.

Cd&
0
 

Author Comment

by:vlg
ID: 7003349
Seems to work!
Cd& - any good links to learn more about layers?

thanks

v
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 7003367
A good place to start with layers in dynamic HTML is:

http://www.dansteinman.com/dynduo/index.html

They have clear explanations and good examples that can be applied to a lot of different situations.

Glad we could help.  Thanks for the A. :^)

Cd&
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question