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 Your First JavaScript Program

i don't understand what code to insert where..

when i preview the code work as it should... i think :)

George- Could you post your code?

let me see what you entered

thank you a lot guys! :D

but it still not working.. :( when i press "check work" it says: " you did not call for document.write function" i don't know what that means, and its not explained in the videos...

Colin Marshall
Colin Marshall
32,861 Points

Can you post the code that you're using in the challenge?

1 Answer

Colin Marshall
Colin Marshall
32,861 Points

You have one mistake with your document.write() command. Your header tags are messed up. You have:

document.write("<h\>Welcome to my site</h>");

It should be:

document.write("<h1>Welcome to my site</h1>");

You're missing the number 1 in both of the header tags and there should be no back-slash in the opening/first tag.

Colin Marshall
Colin Marshall
32,861 Points

The video and the code challenge are slightly different. The code challenge does not ask for h1 tags like Dave puts in in the video. This is how the code challenge should look:

<script>
// Write your code here.
document.write("Welcome to my site");
</script>