(PCC)::[how-to-use-JavaScript-to-change-HTML-content-with-output]::[js]
<!DOCTYPE html> <html> <body> <h2>What Can JavaScript Do?</h2> <p id="demo">JavaScript can change HTML content.</p> <button type="button" onclick='document.getElementById("demo").innerHTML = "Hello JavaScript!"'>Click Me!</button> </body> </html>
JavaScript can change HTML content.