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 trialDarryl Le Roux
Front End Web Development Techdegree Graduate 13,672 PointsFor some reason I am not getting the alert
For some reason I do not get the alert pop-up.
I have tried it by both including the preview.js file, and with just the script.js.
The preview.js works, but the alert does not.
alert("Hey, you're back for more?");
1 Answer
Steven Parker
231,153 PointsThe characters surrounding the script name are not normal quotes but the "curly" variety used in word processing.
Always use these " not these ”
Also, script loading should normally not be done in the "head" area. "Best practice" is to place "script" tags as the last thing inside the "body".
Darryl Le Roux
Front End Web Development Techdegree Graduate 13,672 PointsDarryl Le Roux
Front End Web Development Techdegree Graduate 13,672 PointsVery strange, considering that is how the lesson required it.
To add, I used " in the remainder of the lesson and everything ran perfectly fine. Not sure why it was just that particular module.