Using .innerHTML, we can make the sayHello() function change the content of the paragraph when a visitor clicks on the button.

Set the content of the paragraph to "Website published".

<html>

<body>
  <button onclick="sayHello()">Publish website</button>
  <p id="prompt"></p>
<script>
  function sayHello() {
   document.getElementById("prompt").innerHTML = "Website published!";
  }
  </script>
</body>
</html>]]>

Make sure to add .innerHTML = "Website published!".