Add pagination to htmls