Possible Duplicate:
How to sort an array of javascript objects?
i have a array of objects:
var arr = []
arr[0] = new Object()
...
arr[n] = new Object()
I want to get sorted array by arr[i].getSortOrder() for example, where arr[i].getSortOrder() return integer value. How to do it ?
Just for the record:
For details see Sorting an array of JavaScript objects and the MDN docs for the
sort()method.