javascript functionality set up
added javascript functionality