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![](https://ecs-static.teamtreehouse.com/assets/views/marketing/shared/community-banner-white-47072046c51352fe6a69f5e691ff5700b28bb11d45197d7bdf066d9ea3f72d0c.webp)
![Fidel Zv](https://secure.gravatar.com/avatar/c82db9a26d86afbf447b88bb381faa47?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Fidel Zv
1,625 PointsI don't know how I am supposed to add an opening and closing script tag inside the body of the page. I'm a bit confused
This is what I did and it keeps telling me syntax error but have no clue how to fix it
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
<script>
alert("Here's another message from Treehouse");
<script>
</head>
<body>
<div class="container">
<h1>where to place your Javascript code.</h1>
</div>
<script src="scripts.js"></script>
</body>
</html>
3 Answers
![Dylan Glover](https://uploads.teamtreehouse.com/production/profile-photos/10711971/micro_D46E0734-2CB8-4275-A3B0-8DB3336A4058.jpg)
Dylan Glover
2,537 PointsHey Fidel,
You are going to want to put your <script> tags inside of the <body> tags make sure the closing </script> tag is within the nest of the closing </body> tag. For this challenge you are doing inline scripting and don't need a link to your external javascript page.
It would look like this.
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
</head>
<body>
<h1>where to place your Javascript code.</h1>
<script>
alert("Warning!");
</script>
</body>
</html>
![Piotr Manczak](https://uploads.teamtreehouse.com/production/profile-photos/10607994/micro_20200829_211123.jpg)
Piotr Manczak
Front End Web Development Techdegree Graduate 29,253 PointsBetween <body> and </body>
<script> alert('Warning!'); </script>
![Fidel Zv](https://secure.gravatar.com/avatar/c82db9a26d86afbf447b88bb381faa47?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Fidel Zv
1,625 PointsThanks a lot Dylan