• Resolved sunezapa

    (@sunezapa)


    I can use datatables_order, and I can use default header with export and search and manual sort.
    But when I add ORDER, the header disappear (as in no-datatables).

    Can I add/change the default order (from alfabeticrally first column to something else), and still keep the datatables header?

    I tried by javascrip, but can’t use that as I have one sheet serving many queries, and the do not show same columns. The javascript is common for all views for same google sheet.

    I used this code for canaging default order: datatables_order="%5B%5B 3, 'asc' %5D%5D"

    https://www.ads-software.com/plugins/inline-google-spreadsheet-viewer/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Meitar

    (@meitar)

    I’ve never seen that happen. It’s possible there’s some kind of interaction with another plugin or theme’s stylesheets or scripts.

    Right above the button you pressed to post this question, there’s a line of text that reads:

    Did you include a link to your site, so that others can see the problem?

    Thread Starter sunezapa

    (@sunezapa)

    I did not put a link, to show it, as there was need for the 1000+ users last week to use the filter/search functions.
    Now is more calm time, so I re-activated the default-sort-order in:
    https://detfaellesbedste.dk/program/boern/

    I added datatables_order="%5B%5B 1, 'asc' %5D%5D" to make column B default sort order (time/date).
    The sort is working: It IS sorted in Column B order,
    BUT thje export+seacrh+manual-sort dissapear.
    You can compare to another menu, with same settings, except no code for changing default sort:
    https://detfaellesbedste.dk/program/film/
    Here the order is column A, and Search/export is till visible,.

    Plugin Author Meitar

    (@meitar)

    There are a number of oddities in your code, such as broken inline style (there is no xbackground CSS property), and a strange class value (xno-datatables).

    What are the shortcodes you’re using to produce these results? Are you sure they’re not getting modified somewhere downstream by a plugin or theme?

    Thread Starter sunezapa

    (@sunezapa)

    the “x” in both oddies is my quick way to deactivate the parameter, both for CCC and datatables: By chinging the name to unknown parameter it get disabled, and still available for quick reactivating.
    I have now deleted those parameters, not to disturb code-reading.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Adding datatables_order hides the datatables header?’ is closed to new replies.