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 trialHimanshu Chopra
3,055 PointsHello! Here is my working code. Feedback appreciated & also I need one help!
Can somebody tell me how can print my final output inside the div which has the id 'output'. I tried document.getElementByid('output') and tried to print it inside it but not getting the desired result. Please help me with this!
Here is the Snapshot: https://w.trhou.se/wq9w56vfjr
1 Answer
rydavim
18,814 PointsCan you elaborate? Your code seems to be working for me.
Edit - I originally misunderstood your question, whoops! I now understand what you're asking. I'll update this shortly.
Update
Workspace is failing to load for me at the moment, but you're likely looking for innerHTML.
// Something like...
document.getElementById('output').innerHTML(message);
Hopefully that helps. I'll make sure that works as soon as I can successfully open workspace.
Himanshu Chopra
3,055 PointsHimanshu Chopra
3,055 PointsThanx rydavim. I am sorry if I was wrong in explaining things. Sure you can update it when you have time :)
rydavim
18,814 Pointsrydavim
18,814 PointsI can't open workspace right now, but I've updated the answer to include a documentation link and (probably) working code.