force width for one column but letting others autosize to content & screen
force width for one column but letting others autosize to content & screen
Hello,
In the first column, i have 'details-control' like in this demo page. I would like to force this column width to 25px and not more, but I tried for days many combinations of "autoWidth" : true / false, "responsive": true/false, "columns": [{"className": 'details-control w25px', ...}] where
.w25px{ width:25px; min-width:25px; max-width:25px;}
without success. The size is never modified and I cannot understand why.
I'm using DataTables inside an AdminLTE environment and the table has classes :
<
table id="table2" class="table table-bordered table-striped">
Could you help me setting a small width to this row ?
Many thanks,
T.
This discussion has been closed.
Answers
You need to use the columnDefs parameter to set the width.
You can see an example here
It does not work either : the width of the column is increased when I change the browser width... I put "autoWidth": false and "responsive": false too, and it does not work... The width of the cell is not fixed to 25px...