Hi,
thanks for your post, and sorry for the trouble.
Are you showing both header rows at the same time? Then, no, I’m not aware of keeping those fixed, sorry 🙁
But I thought that you would be hiding one of them, depending on the language? Or are you talking about the “Edit” screen here?
Regards,
Tobias
Thread Starter
secc
(@secc)
Hi Tobias
Thank you for your feedback. Yes, im hidding one row depending on the language.
It would be nice, if i can sort the tables by name and dont have to move them manually into the right position on the backend.
Regards,
Manuel
Hi,
thanks for the clarification. Unfortunately, I don’t really see a way to change the sorting on the “Edit” screen.
The best solution here would probably be to simply use drag and drop (via the row number on the left) to again move the second header row up to the correct position.
Regards,
Tobias
Thread Starter
secc
(@secc)
Hi Tobias. Is there a way, to display it only sorted on the frontsceen? It doesnt have to sorted on the backend. Otherwise i will do it manually as you told before. Best regards. Manuel
Hi Manuel,
yes, that’s possible. You could initiate a JavaScript sort here, once the page loads.
For that, please try adding this to the “Custom Commands” text field on the table’s “Edit” screen:
"order": [ [ 0, "asc" ] ]
That number indicates which column to sort on, in this case the first one, as counting the columns starts with 0. Besides using "asc" for ascending order, you can also use "desc" for descending order.
Regards,
Tobias
Thread Starter
secc
(@secc)
Hi Tobias
This works perfekt, also with the hidden row. Perfect. Thank you for your help. Best regards and a nice afternoon.
Manuel
Hi,
no problem, you are very welcome! 🙂 Good to hear that this helped!
Best wishes,
Tobias
P.S.: In case you haven’t, please rate TablePress here in the plugin directory. Thanks!