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 trialMicheal Jones
3,972 PointsThe Alert command box
Once I make an alert command, the alert box doesn't pop up when I refresh the page. What can be the reason behind why It wont pop up?
3 Answers
Jonathan Grieve
Treehouse Moderator 91,253 PointsHi Michael.
There could be any number of reasons.
alert("Your message here");
Is how the syntax goes.
If you've included it in a function of your own make sure you've called it.
You can also check for console errors in your browser's DevTools. :)
Lukasz Milde
7,201 PointsFile SCRIPT.JS must be nested in JS folder, otherwise SRC address is wrong.
Claire Friloux
6,226 PointsI had a similar issue. Had the code exactly as written but wasn't popping up when ran. Try saving the updated script.js and index.html files then try running it. Mine ended up working after saving the files.
Andy Stevens
Front End Web Development Techdegree Graduate 20,417 PointsAndy Stevens
Front End Web Development Techdegree Graduate 20,417 PointsWithout seeing your code itβs difficult to answer. Have you checked the console to see what if any error messages appear?