implemented Ajax for adding new post