added javascript for posting/add