Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript JavaScript Basics (Retired) Introducing JavaScript Write Another Program

Beth Osburn
Beth Osburn
Courses Plus Student 344 Points

<body> <script> alert ("Good evening")</script> </body> this is my script tag for body of page, what is wrong?

What is wrong with script to body of page? <body> <script> alert ("Good evening")</script> </body>

  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <title>JavaScript Basics</title>
   <script> alert ("Good morning")</script> 
  <script> alert ("Good evening")</script>

Hello Beth, let's take a look at this challenge.

It says to put script tags between the body and put an alert message of "Warning!".

The answer is:

<body> <script> alert("Warning!") </script> </body>

Delete the extra script tag between the <head> tags, change the string to "Warning!" and put alert next to the opening parentheses "alert("Warning!)" Hope that helped.