On Sep 16, 2:16 am, macsig <sigbac...@gmail.com> wrote:
> Hello guys,
> I'd like to know if there is a way to keep a table header fixed on top
> of a div while I scroll the table rows.

I am trying to do the same thing, but I'm debugging something else and
I haven't succeeded yet. My approach has been that of the C coder that
I am:
-- give the header an id; make it display:none (works for me)
-- at onload time, copy that header into another object that is
displayable (the
   content shows up for me but I'm not so sure that the horizontal
spacing -- between
   <th/td>s -- works right).

Some things I found out:
-- I cannot make /only/ the header <tr> behave the way I (and you)
want
-- and I cannot make <thead> work the way it's advertised: it wants to
stay
   fixed vertically, but does not in FF3.5.3, IE7, or Safari.
-- I do not make the displayable header position:fixed because the
displayable
    header stays fixed /horizontally/ too: can't scroll the table left
and right
   and expect that header to follow the body..
-- because no position:fixed, I have to handle vertical scrolling in
JS code, which
   is what I'm working on right now.

If I were a respectable JS coder, I believe I'd have these issues
fixe^h^h^h^h corrected by now. But I'm just a JS beginner so taking
baby steps.

I would very much like to know how you approaching this problem. To
see my developing solution:

  http://sellmycalls.com/cgi-bin/chain

I hope this helps us both!

-- Ben

Reply via email to