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 The Console Challenge

Marko Delgadillo
Marko Delgadillo
4,524 Points

On the 2nd alert pop-up, underneath the message, why does it ask "Prevent this page from creating additional dialogs"?

It asks "Prevent this page from creating additional dialogs" with a check box next to it. Am i doing something wrong?

1 Answer

28,558 Points

No you are not doing anything wrong. That is expected behavior.

The alert dialog has historically been abused by malicious sites to make it difficult for people to leave the site (since the alert temporarily locks up the browser), in order to prevent such abuse many browsers these days will give you the option to prevent alerts when they are used more than once.

It is essentially a security feature in the browser, so it's not something you as a developer has any control over.