upgrading from 1.10.9 to 1.10.11, data part of table becomes centered on page

upgrading from 1.10.9 to 1.10.11, data part of table becomes centered on page

tripletttriplett Posts: 9Questions: 3Answers: 0

the page at
whp.altervista.org/flora-species-list.php
currently works OK and uses:
jQuery 2.1.4, DataTables 1.10.9, Buttons 1.0.3, Column visibility 1.0.3, ColReorder 1.2.0, FixedColumns 3.1.0, FixedHeader 3.0.0, Scroller 1.3.0
the last three add-ons are not used

when I try to upgrade to the latest versions of everything, i.e.
jQuery 2.2.0, DataTables 1.10.11, Buttons 1.1.2, Column visibility 1.1.2, ColReorder 1.3.1
(in the hope that some minor bugs have been fixed),
I find that the data part of the table is centered on the page and does not line up with the table header. I have not changed anything on my page or css. I have only tried it on firefox

You can see the problem at:
whp.altervista.org/flora-species-list-test.php

anyone know if there is a way to fix this?

Answers

  • tripletttriplett Posts: 9Questions: 3Answers: 0

    Note that the "test" version of the page cannot find the .png files used in the header, but this has no affect on the problem.
    also I found that removing colvis and colreorder does not affect the problem

  • allanallan Posts: 61,880Questions: 1Answers: 10,139 Site admin

    If you add either width="100%" or style="width:100%" to your table that will resolve the issue.

    DataTables 1.10.10 and newer are a bit less forgiving about widths as they allow the table to shrink as well as grow. The two options above will make sure it is 100% width like your original page.

    Allan

  • tripletttriplett Posts: 9Questions: 3Answers: 0

    Thanks allan.

    I see that the minor bug I mentioned (header misalignment when you do a search) has also been fixed.

This discussion has been closed.