This forum is no longer open and is for reading/searching only.

Please use our new MachForm Community Forum instead.

MachForm Community Forums » MachForm 2

[closed] Default sort order of manage_entries


  1. wajones
    Member

    Presently the entries grid default display sorts on ID ascending, this appears to be just the display because the query shows the actual data is "order by id asc". Even if I change this to "order by desc" the grid display is still sorted by id ascending.

    How can I change this to display the entries grid to be sorted on id descending to be the default?

    Posted 17 years ago #
  2. yuniar

    Find the code in manage_entries.php around line 200:

    $query = "select * from ap_form_{$form_id} order by id asc $limit";

    simply change the asc into desc
    Did you modify that line?


    MachForm Founder

    Posted 17 years ago #
  3. yuniar

    However, the No. column still displays row numbers in ascending.
    I guess this is what you meant by 'still sorted by id ascending' ?

    If so, for now you can just ignore that row numbers.
    Good point though, I should fix this for the next one.


    MachForm Founder

    Posted 17 years ago #
  4. wajones
    Member

    Yes, that's what I meant, it still shows asc. You say for now just ignore that row numbers. I don't understand what you mean?

    Posted 17 years ago #
  5. yuniar

    After you did the modification, the row numbers will still displayed ascending..as 1-2-3-4 (this is not id, just row number) but the other columns should be sorted correctly (descending)


    MachForm Founder

    Posted 17 years ago #
  6. wajones
    Member

    OK, thanks, I understand now.

    Posted 17 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.