addPost function added