Plug-in to add page length option

Plug-in to add page length option

johncolvinjohncolvin Posts: 2Questions: 0Answers: 0
edited July 2010 in General
I'm trying to add an All option to the page length dropdown. I realize that this could be done easily by editing aLengthMenu, but I want to do it in a plug-in so that when I upgrade to a new version this functionality will remain. I can't find any similar examples. Any thoughts? Thanks.

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Hi johncolvin,

    aLengthMenu is available in the 1.7 betas, and (at least as far as I plan) will be retained in future versions of DataTables. However if you don't want to use it, there are a couple of options:

    - One way to do it which is future compatible is with the language options: http://datatables.net/usage/i18n#oLanguage.sLengthMenu .

    - Write a plug-in which changes the options of the select menu based on an array passed to it.

    Regards,
    Allan
This discussion has been closed.