Pagination helper for RailsPHP