sorting for pages_list