Implemented the next prev buttons