Which of following codes of an event handler records the exact window position of the mouse pointer as it maneuvers across an element?
A) document.getElementById("element1") .onmouseenter = trackPointer; function trackPointer(e) { var hPos = e.clientX; document.getElementById("element2") .innerText;
B) document.getElementById("element1") .onmouseclick = trackPointer; function trackPointer(e) { var vPos = e.clientY; document.getElementById("element2") .innerText = " (" + hPos + ", " + vPos + ") "; }
C) document.getElementById("element1") .onmousemove = trackPointer; function trackPointer(e) { var hPos = e.clientX; var vPos = e.clientY; document.getElementById("element2") .innerText = " (" + hPos + ", " + vPos + ") "; }
D) document.getElementById("element1") .onmouseup = trackPointer; function trackPointer(e) { var hPos = e.clientX; document.getElementById("element2") .innerText = " (" + hPos + ", " + vPos + ") "; }
Correct Answer:
Verified
Q27: The _ event property returns a Boolean
Q28: In the _ phase, the event moves
Q29: Identify the mouse event property that returns
Q30: Which of the following mouse event properties
Q31: Which of the following is the correct
Q33: Which of the following event properties or
Q34: Identify a true statement about the evt.eventPhase
Q35: Which of the following JavaScript methods is
Q36: Identify the event handler that does not
Q37: Which of the following JavaScript expressions is
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents