2 votes

How to move the buttons of Data table?

I have problems with the position of the buttons of the datatable, and I have no idea how to modify the positions, what I want is to put them in another place in the table.

-Something not this: introducir la descripción de la imagen aquí

As usually this this way:

introducir la descripción de la imagen aquí

3voto

According to research right now has to do with the "dom"

https://datatables.net/reference/option/dom

I was the same when he had: dom: 'Bfrtip'

Not found a concrete way to fix it because sometimes the dom works well, and in other passes so that you step to it, which assigns "i" and "p" (information and pagination) as block elements that take up all your bandwidth available and that is why you see information occupying an entire line, and down to the right you see the element of pagination, I would solve it with css, give classes to these elements "the information and pagination" and in these classes turning into elements of type inline-block, I share my solution in codepen:

Datatables Bootstrap 4 buttons to export with style:

https://codepen.io/coderalexis/pen/gKqLEK

if you have questions about the code you can ask me although I think you can understand easily with view.

HolaDevs.com

HolaDevs is an online community of programmers and software lovers.
You can check other people responses or create a new question if you don't find a solution

Powered by:

X