• Resolved an2design4c

    (@an2design4c)


    I understand that you are supposedly unable to use the search and pagination and colspan at the same time and that functionality is controlled by DataTables. Their site has an example that uses all three functions at the same time. Is there a way to get that working properly here?

    Right now I can only get the colspan columns to line up if I insert this code show below in the custom commands field for the table, but if I do this the search function disappears:
    ‘var table =jQuery(‘#bwki_sites_display’).DataTable( { ‘pageLength’: 10, ‘lengthMenu’: [ 10, 20, 50, 100, 200 ], ‘order’: [[ 0, ‘desc’ ]], } ); table.rows().every( function () { var row = table.row( $(this)); html = ‘<i class=”fa fa-plus”></i>Colspan will come here’; row.child(html).show(); $(this).addClass(‘shown’); });’

    As the table is coded now, and I put something in the search box the ‘previous’ and ‘next’ pagination shows up, but this does not show up on initial page load.

    Any suggestions to getting all of these working at the same time?

    https://wordpress.org/plugins/tablepress/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    No, sorry, using DataTables on tables with colspan is not possible in TablePress.
    DataTables itself does support colspan in the table header, but TablePress does not support such complex headers 🙁 Sorry.

    Regards,
    Tobias

    Thread Starter an2design4c

    (@an2design4c)

    Thanks Tobias!

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    sure, no problem, you are very welcome! Sorry that I could not help with a solution here.

    Best wishes,
    Tobias

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Table search and pagination with colspan’ is closed to new replies.