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 trialRobert Kerns
233 Pointsits telling me that i didnt call the function i wrote document.write("<h1> welcome to my site</h1>"); on line 12
im thinking that i need to add another code to call the function that i wrote on line 12 not realy sure how to go about it tho
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
</head>
<body>
</body>
<>
document.write("<h1> welcome to my site</h1>");
</script>
</html>
2 Answers
Andrew Hickman
Full Stack JavaScript Techdegree Student 10,013 PointsDon't forget to write "script" between your empty angle brackets on line 11 ;)
bobdeei
8,575 PointsI'm afraid you got the extra "<>" before calling the function.
Robert Kerns
233 PointsRobert Kerns
233 Pointsim not exactly sure why that was the problem but it worked very helpful thankyou.
Andrew Hickman
Full Stack JavaScript Techdegree Student 10,013 PointsAndrew Hickman
Full Stack JavaScript Techdegree Student 10,013 PointsJust like most other HTML tags, the <script> tag requires both an opening and closing tag. So you just fixed the opening tag, which tells the browser to run the JavaScript between it and your closing tag.