Custom sorting

Custom sorting

gdbarbgdbarb Posts: 2Questions: 0Answers: 0
edited September 2011 in General
Is is possible to sort a table column by a hidden value in each tag or something similar?

I have information with
tags in the cell so sorting by the text would not work correctly. Any ideas would be greatly appreciated.

Thanks in advance.

Replies

  • fbasfbas Posts: 1,094Questions: 4Answers: 0
    yes. there are several sorting functions and hooks for sorting


    you can create a custom sort type (sType and oSort functions)
    http://www.datatables.net/plug-ins/sorting

    custom sort type detection routines (to use oSort without specifying sType) http://www.datatables.net/plug-ins/type-detection

    sort one column based on another's values
    http://www.datatables.net/ref#iDataSort

    or create a custom array of values to sort by for a column (afnSortData)
    http://www.datatables.net/examples/plug-ins/dom_sort.html
    http://datatables.net/development/sorting
  • gdbarbgdbarb Posts: 2Questions: 0Answers: 0
    Thanks fbas! Afer looking at your comment. I think title sorting will accomplish what I need.
This discussion has been closed.