Implementing pseudo-pagination