aaSorting with column name instead of number?
aaSorting with column name instead of number?
Hi,
thank you for your great DataTables, I'm using it on my site and it works great.
I do have a request: would it be possible to use aaSorting with a column name instead of a column number? That would make it easier to use (for me).
Thanks!
thank you for your great DataTables, I'm using it on my site and it works great.
I do have a request: would it be possible to use aaSorting with a column name instead of a column number? That would make it easier to use (for me).
Thanks!
This discussion has been closed.
Replies
It's a good suggestion. I think it future it would be nice to be able to use column names and indexes interchangeably - DataTables can figure out which one is which. However that's probably 2.0 before I'll be able to integrate that in. For now what you could do is have a function which provides a look up - pass it a name and it will give you the column index - a plug-in API method would be ideal for this.
Allan
Look here