On Thu, 24 Sep 2009 11:49:04 +1000, dorayme wrote:
What I am getting is shown here
http://www.jimscot.myby.co.uk/Newcastle_Quayside/Quayside_000_thumbnails.
ht
ml,
if you click on a thumbnail.
...
If you want something at the bottom of the screen then there are a
number of ways of doing this with varying side effects. With the page at
the last URL, you could safely put something at the bottom with absolute
positioning.
Do this:
1. Wrap all the markup you have in BODY in
<div style="position: relative"> [all your stuff] </div>
2. Now *inside* above DIV, anywhere at all *outside* TABLE, add this:
<div style="position:absolute; bottom: 0; width: 100%; text-align:
center;">... A few things here...</div>
...
btw. The text in your captions are way too far vertically from the
thumbnails
Thanks again.
I already have a wrapper #page in my stylesheet that sets the max width,
margin and font properties. Do I add your first <div> or just add
position
relative to mine?
There is no wrapper at the URL you quote above. So if you do exactly
what I said above for that page, you should be right. As for other
pages, I can only explain the general principle for you as best as I
understand it:
In brief, because of the rules of absolute positioning, any element so
positioned takes as its reference either the viewport (top: 0; left: 0;
gets the absolutely positioned box's top left corner nuzzled right up to
the top left corner of a normal visual browser window), or else the
closest ancestor element that is any position: x; where x is relative,
absolute or fixed. The default, which you almost never actually see, is
position: static. That is no good for our purpose here. That is what you
and I usually operate with and it is supplied automatically by the
browser.
The real and proper function for relative position is to offset stuff
from its normal position. But some people who know what they are doing
use it to have something else but the viewport (the html element for
some browsers no doubt) to be the reference point for some element that
is needing to be positioned. Simply because it is *other* than position:
static, an element can act as the reference point for a child or
descendant that *is* absolutely positioned. It is a useful side effect.
A bit like how it might be appreciated that one's partner has a high
fever - for a bug that one is immune to - on a freezing night.
Anyway, for practical purposes, and to simplify, if you want some
element B to be in a very specific place inside some element A, it is a
worthwhile ploy to position: relative that A element. This makes B
suddenly rush to place itself with respect to A. It treats A as home
rather than the cold imperious viewport. Believe me, VIEWPORT has no
warmth or any real empathy for its contents. I have evidence that it is
contains stuff on sufferance, duty, not out of loyalty or good
heartedness.
<
http://dorayme.netweaver.com.au/alt/absolutely_one.html>
<
http://dorayme.netweaver.com.au/alt/absolutely_two.html>
may help you understand this matter a little more. Copy paste the source
from the view menu of the latter especially and stick it on in your text
editor and remove position: relative from body and put it on the green
div and see what happens.
In case you are puzzled by the effect of position: relative on the real
position of the element so positioned, it has no effect at all if you do
not supply offsets with the top, left, bottom, right properties. It just
quietly announces that it is staying right where it is and that any
decendant that is positioned absolute is welcome to call it home.