I made a simple don't press the button game and there are two errors (the other will be in a different question) Unexpected text this is the code I wrote:
<body>
<h1>Don't press the button</h1><br/>
<p>DON'T PRESS THE BUTTON</p>
<div class="round-button">
<button type="button" onclick="alert('Why Did You Press Me. The next button you click will have consequences')">Don't Click Me</button>
</div>
<div class="hint-text">
<p><b>V V V V</b></p>
</div>
<div class="round-button button2">
<button type="button" onclick="alert('Ok, this is your last chance. Don't press anymore buttons... not that there are any')">NOT A BUTTON</button>
</div>
and this is the code in the web page:
<body>
"Don't Press the Button "
<h1>Don't press the button</h1><br/>
<p>DON'T PRESS THE BUTTON</p>
<div class="round-button">
<button type="button" onclick="alert('Why Did You Press Me. The next button you click will have consequences')">Don't Click Me</button>
</div>
<div class="hint-text">
<p><b>V V V V</b></p>
</div>
<div class="round-button button2">
<button type="button" onclick="alert('Ok, this is your last chance. Don't press anymore buttons... not that there are any')">NOT A BUTTON</button>
</div>
</body>
As @K Scandrett said in their comment, the apostrophe in "Don't" is causing your problem. You need to escape it by putting a "" before, like this:
onclick="alert('Ok, this is your last chance. Don\'t press anymore buttons... not that there are any')">NOT A BUTTON</button>
</div>
</body>
Escape characters are used to remove the special meaning from a single character, and instead preserve the literal value. In this case, the quote within "Don't" was causing the program to read that as the end of the string, and ignore the rest of that line. That's why you got this error:
{ "message": "Uncaught SyntaxError: missing ) after argument list", }