|
Posted by rf on 09/25/07 11:59
"Neredbojias" <monstersquasher@yahoo.com> wrote in message
news:Xns99B626D13FC8nanopandaneredbojias@198.186.190.161...
> Well bust mah britches and call me cheeky, on Mon, 24 Sep 2007 22:05:21
> GMT
> scribed:
>
>> Hi
>>
>> I'm learning to use the DIV tag and am having some problems dividing a
>> page into two horizontal sections.
>>
>> I want a div area that goes across the top of the page (which I can
>> get to work), then two sections that sit next to each other and go all
>> the way to the bottom of the page.
>>
>> How do I get two div sections to sit next to each other horizontally?
>
> I subscribe to Andy's well-presented opinion on the matter. However, divs
> don't go "all the way to the bottom of the page" if the content is
> insufficient unless the author does something which is usually wrong.
> That's a fact to bear in mind particularly when considering backgrounds.
Further, what exactly is the "page"?
Usually, with a really simple HTML file, it is the end of that HTML file.
The bottom of the "content". Where the browser stops scrolling when one
leans on ones page down button, because said browser can't go down any more.
There is nothing further. Therebelow lie dragons.
However if one distrupts the usual content flow by introducing floated
elements or <shudder> absolutely positioned elements </shudder> then one
totally loses the concept of the "page".
Where is the bottom of the "page" for a floated element? The bottom of the
element? The bottom of the surrounding content?
Where is the bottom of the "page" for an absolutely positioned div element?
Where is the bottom of the "page" for an absolutely positioned div element
where top: 1000px; has been specified? (try it and see, you will need to
scroll down). Indeed if that element is the only one in the body of the
HTML file where is the "top" of the "page"? Pixel 0 or pixel 1000?
Hint: We don't actually know.
The best we can guess is that, after the browser has done its best to lay
out the content, after due consideration to these floated and positioned
elements, the bottom of the page is where there is nothing more. That is,
the browser does not need to draw anything below this point. You have
reached the end of the scroll bar. And no, there is no CSS property to
position something at the end of the scroll bar, least of all the bottom of
an element :-)
In any case HTML files do not describe "pages". They describe content, with
CSS to pretty that content. The browser lays out the elements containing the
content as it sees fit, with the CSS taken into account. Why should we ask
more? "Page" is for print, not web.
Ah, but I see I have just upset a considerable number of graphic artists who
think they are web drezigners ;-)
OP: Why do you need to divide your content into two sections side by side?
There are a [google] number of ways to do this. Show your best effort.
--
Richard
[Back to original message]
|