Adding the while loop for the post