Title: WP-Table Reloaded multiple column sorting issues
Last modified: August 20, 2016

---

# WP-Table Reloaded multiple column sorting issues

 *  [cyandle](https://wordpress.org/support/users/cyandle/)
 * (@cyandle)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/)
 * I have a column of rankings yet for some reason it will not sort any column correctly
   except for the main column and that’s just on the initial page load. It sorts
   it as 1, 11, 12, 13, etc instead of 1, 2, 3, 4, etc. I’ve tried a lot of the 
   stuff mention in other posts but with no luck. Thoughts?
 * [http://dynastysportsempire.com/dynasty-football-qb-rankings/](http://dynastysportsempire.com/dynasty-football-qb-rankings/)

Viewing 7 replies - 1 through 7 (of 7 total)

 *  [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943160)
 * Hi,
 * it seems that you have deactivated Sorting at this time. Can you please activate
   it again?
 * The reason for the wrong sorting could be the “N/A” entries. Those will change
   the column data type to strings, which are sorted differently. If you just leave
   those cells empty, it should work.
 * Also, you should remove the “Custom Command” for currency sorting that you seem
   to have added to this table.
 * Regards,
    Tobias
 *  Thread Starter [cyandle](https://wordpress.org/support/users/cyandle/)
 * (@cyandle)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943162)
 * Re-enabled. Was fixing another issue with the table.
 *  Thread Starter [cyandle](https://wordpress.org/support/users/cyandle/)
 * (@cyandle)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943171)
 * The blank spaces just show up at the top.
 *  [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943249)
 * Hi,
 * thanks for removing that “Custom Command” again.
    However, sorting seems to be
   deactivated again…
 * And what do you expect instead of the empty cells being sorted to the top?
 * Regards,
    Tobias
 *  Thread Starter [cyandle](https://wordpress.org/support/users/cyandle/)
 * (@cyandle)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943251)
 * I enabled it on a lesser important page for you: [http://dynastysportsempire.com/dynasty-football-te-rankings/](http://dynastysportsempire.com/dynasty-football-te-rankings/).
 * I would expect the blanks to be at the end and 1 to be at the front since we’re
   using it to “rank” the players.
 *  Thread Starter [cyandle](https://wordpress.org/support/users/cyandle/)
 * (@cyandle)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943252)
 * If you click on the MD column you will see how it looks with a lot of blanks 
   at the beginning.
 *  [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943258)
 * Hi,
 * thanks for the example.
 * I guess that the blanks being at the top is simply the default for the DataTables
   JS library (which WP-Table Reloaded uses for the sorting), basically because 
   they are treated as “0”, which comes before “1” obviously.
    Unfortunately, I 
   don’t know if this behavior can be altered easily. Probably, you will need a 
   custom sorting algorithm, for which I would recommend [http://www.datatables.net](http://www.datatables.net)
   as a starting point.
 * Another idea would be to just enter a higher number/rank here, if that is possible
   without being meaningless?
 * Regards,
    Tobias

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘WP-Table Reloaded multiple column sorting issues’ is closed to new replies.

## Tags

 * [[Plugin: WP-Table Reloaded]](https://wordpress.org/support/topic-tag/plugin-wp-table-reloaded/)

 * 7 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [13 years, 10 months ago](https://wordpress.org/support/topic/wp-table-reloaded-multiple-column-sorting-issues/#post-2943258)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
