SyntaxFix
Write A Post
Hire A Developer
Questions
getElementById returns a reference to the element using its id. The element is the input in the first case and the paragraph in the second case.
getElementById
id
input
https://developer.mozilla.org/en-US/docs/Web/API/document.getElementById