Scroll table without scrolling the page?

M

Max Moor

Hi All,
I'm using FP2003, and I'm trying to get a web page to scroll a certain
way.

The page has thee tables/cells defined: a header across the top, a nav
bar down the left side, and a main text area. I've defined a background
image as a watermark, so it's behind all three. What I want is for only the
main text area to scroll, though, without the header and nav bar to scroll
off screen.

I added a <div> to the main area with 'overflow:auto', but it's not
quite doing what I want. First, it only seems to scroll the main area if the
mouse is over it. I'd like the main area to "have the focus" no matter where
the mouse pointer is.

Also, whever the main area is scrolled to it's limits, the whole page
begins to scroll, with the header and side nav going off screen. I really
want the main area to scroll, but the header, nav, and background image to
stay put.

Finally, if possible, I'd like all this to work without any scroll bars
having to be displayed. At least, if they have to be displayed, it would be
nice if they stay on the right edge, out of the way.

Can the behavior I want be gotten easily? (I'm obviously not an expert
at this.)

- Max
 
R

Ronx

If you use a scrolling div, you will have 2 scroll bars - 1 for the page
itself if the whole page is taller than the browser portal, and 1 for
the div if its content is about to overflow.
If the whole page scrolls, then your page is too tall for the portal and
you are using the page scroll bar on the right margin. The div's scroll
bars will always be inside the div.
Focus is always where the mouse pointer was last clicked, or somewhere
off the page if the mouse (or tab key) has not been used on that page.
Any scroll bar in the div will always show when it is needed (otherwise
use overflow:hidden - but this will also hide the text that does not fit
into the div), regardless of where the mouse is, however if there is any
mouseover event that effects the size of the text in the div then this
may toggle the necessity for the scroll bar, and it will appear and
vanish according to the position of the mouse.
 

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

Top