Okay
  Public Ticket #1817313
Show 100 entries but retain container size of 10 entries.
Closed

Comments

  •  1
    alsonjonsolutions started the conversation

    Hi Administrator.

    I really like the container size of showing 10 entries but would like to check if I were to show 100 entries. Is it possible to add any CSS styling to make it retain the container size of 10 entries and the ability to vertically scroll down. Do let me know what are the codes to do so if possible! Thanks!


    In addition, right now the advanced filter has the field has the placeholder of the column header. Is there anyway to remove this and show a blank field instead?

  •  2,498
    Aleksandar replied

    Hello alsonjonsolutions.

    Thank You for Your purchase.

    You'd need to enable the Scrollable slider under table's Display settings.

    After that, add this code to the Custom JS and CSS under main Settings of wpDataTables:

    .wpDataTablesWrapper div.wdtscroll {
        height: 310px;
    }

    You can edit it any way You'd like, of course. The result is shown in the attachment - 10 rows visible, others are scrollable. The only difference is that I don't have 100 rows in the table I created for testing purposes, but only about 20. Works good, that's the important thing.

    As for removing the column header placeholder, You'd need to open the next file:

    wp-content/plugins/wpdatatables/assets/js/wpdatatables/wdt.columnFilter.js

    And simply delete the name of the placeholder for each of Your columns.

    Example:

    <input type="text" class="form-control wdt-filter-control text_filter" placeholder="Product">

    Has the following result:

    While this:

    <input type="text" class="form-control wdt-filter-control text_filter" placeholder="">

    Has the following result:

    Please let me know if this helps.

    Best regards.

    Kind Regards, 

    Aleksandar Vuković
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables