Microsoft
98-382 · Question #30
98-382 Question #30: Real Exam Question with Answer & Explanation
Sign in or unlock 98-382 to reveal the answer and full explanation for question #30. The question stem and answer options stay visible for context.
Question
You are designing a web page with a script that must dynamically change the content of a paragraph element to display the value returned by the function randomQuote().
You have created the following code. Line numbers are included for reference only.
01 <!DOCTYPE html>
02 <html>
03 <body>
04 <p id="tester" onclick="changeText()">Click to change the content.</p>
05 <input type="button" value="Change Text" onclick="changeText()" />
06 <script>
07 function changeText() {
08 }
09 </script>
10 </body>
11 </html>
Which code segment should you use at line 08?
Options
- Adocument.getElementById("tester").value = randomQuote();
- Bdocument.getElementById("tester").title = randomQuote();
- Cdocument.getElementById("tester").innerHTML = randomQuote();
- Ddocument.getElementById("tester").script = randomQuote();
Unlock 98-382 to see the answer
You've previewed enough free 98-382 questions. Unlock 98-382 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.