PrepAway - Latest Free Exam Questions & Answers

You are creating a JavaScript function that displays the name of a web application.

You are creating a JavaScript function that displays the name of a web application.

You declare the following button element.



When a user clicks the button, a JavaScript function named Contact must be called.

You need to create an event handler that calls the Contact function when the button is clicked.

Which two code segments can you use? (Each correct answer presents a complete solution. Choose two.)



A. Option A

B. Option B

C. Option C

D. Option D

Explanation:

https://www.w3schools.com/jsref/met_element_addeventlistener.asp

One Comment on “You are creating a JavaScript function that displays the name of a web application.


Leave a Reply