update 'prev-next' functionality