Are there any additional parameters besides the message accepted by the alert / confirm native JavaScript methods?
Specifically I would like to highlight the cancel button rather than the ok.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you need to do this, the way to get what you want is to concoct your own dialogs.
I’m not sure why any site design that takes itself seriously would ever use the built-in dialogs in the absence of some evidence that web users recognize some semantic content from those things (which I seriously doubt).
Oh, and the basic way to do this is to populate a
<div>with your dialog content; position it absolutely (or whatever, depending on your overall situation); and show it in front of a div that covers the whole page with partial opacity or something so that the dialog is “modal” (with respect to your own page). Various libraries provide ways to do that, some more fancy than others. The point is that since it’s your own dialog, you can style anything you like.