div id positioning w.r.t. bottom

J

James Mercola

Hello,

is there any kind of code for layers using div id's that will position an
element in relation to the bottom of the browser window? in this case i
have a bottom navigation bar that should stay at the bottom of the page, but
I can't seem to locate any postioning code relative to page bottom...

thanks for any input

james
 
T

Toby Inkster

James said:
is there any kind of code for layers using div id's that will position an
element in relation to the bottom of the browser window?

html, body {
height: 100%;
}
#mything {
position: absolute; /* or "fixed" */
bottom: 10px;
left: 10px;
}
 
M

Mark Parnell

is there any kind of code for layers using div id's that will position an
element in relation to the bottom of the browser window?

See Toby's post for how to do it, but what happens if the page is longer
than the browser window? You _could_ use position: fixed; but IE doesn't
support it.
 
R

rf

James Mercola said:
Hello,

is there any kind of code for layers using div id's that will position an
element in relation to the bottom of the browser window? in this case i
have a bottom navigation bar that should stay at the bottom of the page, but
I can't seem to locate any postioning code relative to page bottom...

You use two terms here, bottom of browser window and bottom of page.

Bottom of page does not equal botttom of browser window.

A bottom navigation bar should naturally be at the bottom of the page, that
is the bottom of the document. That, for example, is where google put their
bottom navigation.

If you put the navigation at the bottom of the browser window then it will
be permanently covering up some of the content and could possibly confuse
your viewer.
 
M

Mark Parnell

On Tue, 24 Aug 2004 04:09:28 GMT, rf <[email protected]> declared in alt.html:

<snip>

Welcome back, Richard. Been at the snow?

BTW: You do realise this thread is over a week old now?
 
N

Nik Coughin

rf said:
If you put the navigation at the bottom of the browser window then it
will be permanently covering up some of the content and could
possibly confuse your viewer.

Just wondering, what if you had a navigation at the bottom of the *window*
that was, say, 3em high, and then had a 3em margin-bottom for the content?
I'm going to try it, be right back!

(ten minutes later...)

Works perfectly in Opera and Mozilla, page doesn't look as expected in IE
(had a quick play with some position-fixed hacks for IE but didn't get it
working) but is still usable:

http://www.nrkn.com/bottomNav/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top