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 trialJonathan Nimene
473 Pointsnot understanding
i've been stuck on this too long i just need the answers at this point, please help.
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
<script type="text/javascript">
</script>
<body>
<script>
<body>
<script>
</html>
1 Answer
Tiwong Nance, Jr.
19,650 PointsHi Johnathan. Let's tackle this step by step. First, we need to insert script tags between the body tags:
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
</head>
<body>
<script>
</script>
</body>
</html>
Now, we have to write an alert function that displays 'Warning!' We can do that with this between the script tags:
<script>
document.write(alert('Warning!'));
</script>
This is basically telling the Document Object(The current window for the HTML document) to write an alert of type String (single or double quotes qualify for a string) that says Warning! Hope this helped out. :)
Jonathan Nimene
473 PointsJonathan Nimene
473 PointsThank You so much that helped big time !