Move the Show entries (dataTables_length) dropdown to footer

Move the Show entries (dataTables_length) dropdown to footer

sjw01sjw01 Posts: 67Questions: 36Answers: 1

Is there an easy way to move the dataTables_length dropdown (and search ) to the footer?

This question has accepted answers - jump to:

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    edited April 2018 Answer ✓

    Hi @sjw01 ,

    Yep, the dom gives you control on where those elements are placed. Take a look at this example,

    Cheers,

    Colin

  • sjw01sjw01 Posts: 67Questions: 36Answers: 1

    I have changed the order in which items are loaded, switching to flrtip BUT the order is still outputting as lfrtip

    http://live.datatables.net/lidequra/1/edit

    Does it not change automatically? Do I need to edit the CSS?

    Is this setting relevant if I just need to edit the CSS?

  • colincolin Posts: 15,240Questions: 1Answers: 2,599

    Hi sjw01,

    Take a look at this one: http://live.datatables.net/lidequra/3/edit

    Cheers,

    Colin

  • sjw01sjw01 Posts: 67Questions: 36Answers: 1

    Thanks.

    I'm still having issues though - I updated the code and was able to re-arrange fields to different places which is what I wanted BUT i can't get the top elements to switch:

    see here: http://live.datatables.net/lidequra/5/edit

    Bottom: perfect (except pagination needs top alignment but I can do that with CSS)

    Top: I want search on left and buttons on right - I can see in the code that search is printed first and buttons second BUT the CSS floating is forcing them to opposite sides?

    I can just switch this with CSS but want to confirm that I am not doing it wrong?

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    Answer ✓

    No, I think you're right, it seems the Buttons are going to the left regardless of the DOM setting, so it probably needs CSS as you said.

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    Answer ✓

    Yep, just been told the default CSS has float:left for the buttons, so that'll need to be changed. This area is on the roadmap to be improved.

This discussion has been closed.