Closed Samadhan1012 closed 7 years ago
The easiest way to do this would be to just have the original data inputted as desc.
OK. But how as I add new recors, it will be final row in MySql too. Can you plz clarify me little bit? I want latest record to be displayed on first page and first row.
The query which you use to pull the data use a order by [id if you have one] desc when putting in the data this will make the most recent record become the top ones.
/**
use EditableGrid.sort(columnIndexOrName, descending, backOnFirstPage)
Thanks for the comments. It's working when changed from ASC
to DESC
in loaddata.php:
if ( isset($_GET['sort']) && $_GET['sort'] != "" ) $query .= " ORDER BY " . $_GET['sort'] . ( $_GET['asc'] == "0" ? " DESC " : "" );
First of all thank you so much for the nice and fabulous table. I want to default sort "ID" column in descending order. How can I make this?