adding js for callbacks