Add sorting to index page