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 Treehouse Club - MASH MASH - JavaScript Stuff You Can Change

Huub Langedijk
Huub Langedijk
5,039 Points

How come nothing happens at all when I press the Tell my fortune button? How do I reset the code?

In the video whenever the button is pressed on the site, a box appears where it says undefined for the variables. Whenever I press Tell my fortune however it looks like it only refreshes my page. As far as I can tell I only made changes to the CSS part.

Can i somehow reset my code or get the version the teacher is using? Everytime I launch the workspace it opens my altered version.

2 Answers

Josian Acevedo
Josian Acevedo
3,662 Points

In the index.html, make sure at the bottom of the code you have the following line:

<script src="script.js"></script>

I think you are missing "script.js"

Josian you are a lifesaver. I had the same problem and was reading through everyone's code and was about ready to start over.

Chris Davis
Chris Davis
16,280 Points

I think you have to go into workspaces in the upper right hand corner of the screen, next to your profile count/avatar, find that workspace and delete it. Then go back into the lesson and when you open that workspace it should be reset.

I have the same problem but I do not want to delete the entire project I have been working on. Do you know another way to get the JS to work without deleting the workspace file?