Took out echo query for paginate