Added pagination to q_post class