added more javascript comments