Fixed columns issue

Fixed columns issue

essexstephessexsteph Posts: 57Questions: 0Answers: 0
edited June 2013 in General
I'm needing to use the fixed columns plugin but I'm having a couple of issues which you can see at http://pttmulti.bitnamiapp.com/trackinggrid-issue.php.

The first is that as you scroll the column headings are visible as they move past the headings for the fixed columns. Secondly the headings are out of alignment with the data columns and thirdly in Chrome but not IE the horizontal scroll bar can't be dragged until you use the arrow to move it out of the fixed columns area.

Any suggestions gratefully received.

Steph

Replies

  • essexstephessexsteph Posts: 57Questions: 0Answers: 0
    Really would be grateful if you could point me in the right direction, I've tried various things but sure I'm missing something stupid.

    Thanks.
  • allanallan Posts: 63,516Questions: 1Answers: 10,472 Site admin
    Hi,

    So there are a few things going on here, which cumulating in it being a bit broken. First this is to remove the cell spacing (with cellspacing="0" on the table tag) and browsers can do funny things with column width with cell spacing.

    Secondly, remove sScrollXInner. It should also never be used and I'm thinking of removing it. It will certainly be highlighted in the updated documentation that it shouldn't be used and I'm going to remove it from my demos. It throws the calculations way out.

    Third, remove iLeftWidth from the FixedColumns initialisation. FixedColumns 2.5 takes the width entirely from the source table. I'm going to be removing iLeftWidth from 2.5.

    Fourth, update to the latest FixedColumns to address the problem with not being able to use the scrollbar.

    Fifth, add `th { white-space: nowrap }` to your CSS, which is what I think you were probably trying to do with the sScrollXInner.

    And that should be it: http://datatables.net/clients/essexsteph/pttmulti.bitnamiapp.com/trackinggrid-issue.php.html :-)

    Allan
This discussion has been closed.