Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82037

Using Responsive with Details Column and AJAX Data

$
0
0

I see from the examples that it is indeed possible to use Responsive with AJAX data, but in the example, the show/hide button is in the first cell. I use the following in my DataTable markup:

responsive: {
    details: {
        type: 'column'
    }
},

I typically like to have the button in its own column, that only appears when the viewport triggers the Responsive extension by having an empty <th></th> and an empty <td></td> to contain the show/hide button.

However, my AJAX data does not contain an empty first column, and the <tbody> structure is rendered by DataTables for the AJAX data. I have tried putting an empty column using columns.data (didn't work), so I am starting to wonder if it is not possible to have a dedicated column for the Responsive show/hide buttons with AJAX data.

Is this possible?


Viewing all articles
Browse latest Browse all 82037

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>