Adds previous and Next buttons and paging