logo
🥇 Top contributors

💌 Submit a question

Add a new question

Select the Category:

Question:

Choice 1:

Choice 2:

Choice 3 (Optional):

Choice 4 (Optional):

Correct Answer:

Explanation:

Hint (Optional):

Code (Optional):

Your Twitter (for credit):

Javascript

innerHTML

Pick an answer

See all questions


<p id="demo">My awesome text</p>

Question 23 of 49

What is the correct JS syntax to change the content?

#demo.innerHTML = "Edited!"
document.getElementById("demo").innerHTML = "Edited!"
document.getElementByName("p").innerHTML = "Edited!"
Previous
Next