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

Darnekka Davila
Darnekka Davila
401 Points

Treehouse is failing me right now.this lesson still not accepting my work when i know its right

why is this wrong

index.html
<!DOCTYPE HTML>
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <title>JavaScript Basics</title>
  <script src="script.js"> </script>
  <script>
    alert("Warning!");
  </script>
</head>
</body>
</html>
Luke Hayes
seal-mask
.a{fill-rule:evenodd;}techdegree
Luke Hayes
Python Web Development Techdegree Student 1,230 Points

The challenge is asking you to put the script tags in the body and you have them in the head of your HTML file. First you need to add an opening body tag <body> and in between that tag and you closing body tag </body> add your script tag with the alert function.