create sort method in page (unfinished)