Simplify your online presence. Elevate your brand.

Column Width Not Working Datatables Forums

Column Width Not Working Datatables Forums
Column Width Not Working Datatables Forums

Column Width Not Working Datatables Forums It does this to try and avoid column widths jumping when paging through the table. in short, the widths you give are used, but if the table's content doesn't fit into them, or they don't add up correctly, the browser and datatables will overrule you and use the widths only as a guide. I am using the following code to set the column width of a datatable. during partial page load the width appears to be correct and when it loads completely, the width is off.

Column Width Not Working Datatables Forums
Column Width Not Working Datatables Forums

Column Width Not Working Datatables Forums In this guide, we’ll explore all methods to set column widths in datatables, from basic css tweaks to advanced datatables specific configurations. whether you’re working with fixed pixel widths, responsive percentages, or dynamic content, this guide will help you master column width control. I need to dig into what datatables is doing when auto width is disabled i can't recall off the top of my head! i remember trying to simplify it for v2, and i came close to removing the auto width option entirely (i've long regretted putting it in :)). I'm working on creating a sample using my code to share as it's difficult for me to link to the page. will be posting that soon as i haven't had much luck with this issue and have tried quite a few different things to force the column widths. The browser will collapse the width if there isn't enough space for it and everything else in the table (which can be seen in that example if you make the output frame narrow). if that doesn't work for you, please follow the forum rules and post a link to a test case showing the issue so we can help to resolve it. allan.

Column Width Not Working Datatables Forums
Column Width Not Working Datatables Forums

Column Width Not Working Datatables Forums I'm working on creating a sample using my code to share as it's difficult for me to link to the page. will be posting that soon as i haven't had much luck with this issue and have tried quite a few different things to force the column widths. The browser will collapse the width if there isn't enough space for it and everything else in the table (which can be seen in that example if you make the output frame narrow). if that doesn't work for you, please follow the forum rules and post a link to a test case showing the issue so we can help to resolve it. allan. I have specified column width (15%) in 'columndefs' as below, it's not forcing to pick up the specified width, it's taking width as per length of data. Happy to take a look at a test case showing the issue. note that there is no column.width() method as your () suggests. i suspect you mean columns.width. but still we'd need a link to a test case. allan. Hello i've seen other working examples, but i tried a lot of things and still the fixed column width is not working on my table. I've tried setting the style's width:100% within the table to no avail. your test case isn't running. its has these errors: fixed by moving the responsive.js library to load after everything else. fixed by commenting out the line of code referencing nametype. looks like your table is responsive.

Column Width Datatables Forums
Column Width Datatables Forums

Column Width Datatables Forums I have specified column width (15%) in 'columndefs' as below, it's not forcing to pick up the specified width, it's taking width as per length of data. Happy to take a look at a test case showing the issue. note that there is no column.width() method as your () suggests. i suspect you mean columns.width. but still we'd need a link to a test case. allan. Hello i've seen other working examples, but i tried a lot of things and still the fixed column width is not working on my table. I've tried setting the style's width:100% within the table to no avail. your test case isn't running. its has these errors: fixed by moving the responsive.js library to load after everything else. fixed by commenting out the line of code referencing nametype. looks like your table is responsive.

Responsive Column Width Datatables Forums
Responsive Column Width Datatables Forums

Responsive Column Width Datatables Forums Hello i've seen other working examples, but i tried a lot of things and still the fixed column width is not working on my table. I've tried setting the style's width:100% within the table to no avail. your test case isn't running. its has these errors: fixed by moving the responsive.js library to load after everything else. fixed by commenting out the line of code referencing nametype. looks like your table is responsive.

Comments are closed.