Glossary: JavaScript in the Browser
innerHTML
A property that reads and writes an element's contents as HTML. Setting it with text you didn't write lets attackers inject code, so use textContent instead.
Glossary: JavaScript in the Browser
A property that reads and writes an element's contents as HTML. Setting it with text you didn't write lets attackers inject code, so use textContent instead.