We're Moving to a New Support Platform – Starting June 1st!

We’re excited to let you know that starting June 1st, we’ll be transitioning to a new support system that will be available directly on our product websites – Amelia, wpDataTables, and Report Builder. In fact, the new support platform is already live for Amelia and wpDataTables, and we encourage you to reach out to us there.

You'll always be able to reach us through a widget in the bottom right corner of each website, where you can ask questions, report issues, or simply get assistance.

While we still do not offer live support, a new advanced, AI-powered assistant, trained on our documentation, use cases, and real conversations with our team, is there to help with basic to intermediate questions in no time.

We're doing our best to make this transition smooth and hassle-free. After June 1st, this current support website will redirect you to the new "Contact Us" pages on our product sites.

Thanks for your continued support and trust – we’re excited to bring you an even better support experience!

Okay
  Public Ticket #2884682
Select Entries Drop-Down
Closed

Comments

  • Dalton started the conversation

    Is there any way that we can add options to the "Select _ Entries" dropdown menu? For example, we are wanting to add options for 250 and 500 rows per page, since the jump from 100 rows, to all rows is a little too much. Thanks!

  • [deleted] replied

    Hi Dalton

    Thank you for reaching out to us.

    Something like this will require some code changing which is not included in our support I'm afraid.  

    I can tell you where to look but please be aware that these changes will be lost after the update of the plugin.

    This is a guide for adding 1000 - you would simply replace 1000 with the desired number.

    You need to open this file: ../wp-content/plugins/wpdatatables/templates/admin/table-settings/table_settings_block.inc.php and around line 335 you'll see this:

    <select class="form-control selectpicker" id="wdt-rows-per-page">   <option value="1">1</option>   <option value="5">5</option>   <option value="10">10</option>   <option value="25">25</option>   <option value="50">50</option>   <option value="100">100</option>   <option value="-1"><?php _e('All', 'wpdatatables'); ?></option>
    </select>

    You can replace the last option (All) with the 1000 option, like this:

    <select class="form-control selectpicker" id="wdt-rows-per-page">   <option value="1">1</option>   <option value="5">5</option>   <option value="10">10</option>   <option value="25">25</option>   <option value="50">50</option>   <option value="100">100</option>   <option value="1000">1000</option>
    </select>
    

     And you'll have that option in the "Display" tab above the table:

    7120173477.png

    Then, open ../wp-content/plugins/wpdatatables/source/class.wpdatatable.php and around line 3207, and replace "All" with 1000, so it looks like this:

    $obj->dataTableParams->aLengthMenu = json_decode('[[1,5,10,25,50,100,1000],[1,5,10,25,50,100,1000]]');
    

    And the last thing to do is to go to line 499 of the same file, and modify it so it looks like this:

    public function setDisplayLength($length) {        if (!in_array($length, array(1, 5, 10, 12, 20, 25, 30, 50, 52, 100, 200, 1000))) {            return false;        }
    

    So, again, replace -1 with 1000.

    You may also want to add the value in ../wp-content/plugins/wpdatatables/templates/admin/table-settings/column_settings_panel.inc.php around line 570, if you wish to add that value to possible column options (if you have a select-box filter, or selectbox editor input type, this would be the number of values displayed in those drop-downs).

    Please make sure to delete cache in your browser after you apply the changes.