1

I used the following to display message on clicking HREF

<td align="center" style="background-color: #99ccff; border: 1px solid #000;" class="style22">
                        <a href="" onclick="return confirm('Select This Opton for qualifying asylee/refuge status students who require');">?</a>
                    </td>

This works fine. But my question is on IE it is displaying the pop up with a question mark where as in other browsers it doesn't how can i have that as per in IE

enter image description here

On IE i am getting as mentioned and also i would like to display the title as per my own instead of Message from webpage i would like to write a custom one how can i can any one help

Developer
  • 8,390
  • 41
  • 129
  • 238

5 Answers5

3

There are no options to customise the confirm popup box.......

You can try using a modal dialog box that resides within the page, however. jQuery UI has a nice one: http://jqueryui.com/demos/dialog/#modal-confirmation

foxy
  • 7,599
  • 2
  • 30
  • 34
2

While it is not possible to customize the default browser confirm (or alert) popup, it's perfectly possible to implement your own and use that instead. In doing so, you can customize anything you like, from title to buttons to colour.

Have a look at this site, which provides a JavaScript library for doing just that.

James Allardice
  • 164,175
  • 21
  • 332
  • 312
  • +1 Looks like a good library, probably better than jQuery UI for something like this. – EMP Jun 18 '11 at 09:24
1

Refering to Changing the default title of confirm() in JavaScript?, You can not override the default title of a javascript confirmation dialog.

You still have other options like JQuery Dialog.

Community
  • 1
  • 1
Akram Shahda
  • 14,655
  • 4
  • 45
  • 65
1

Every browser implements their own pop up window. IE just so happens to use a silly question mark. You can only customize the message that appears within the alert box. If you want to customize the entire look and feel of an alert box, you need to roll your own by creating a div that appears to hover over your content.

djibouti33
  • 12,102
  • 9
  • 83
  • 116
0

Unfortunately the JavaScript confirm function does not give you any control over the title, icon or any other aspects of the dialog. If you want a custom dialog I'd suggest you instead show a <div> that looks a bit like a dialog. It can then look however you want it to look. jQuery UI Dialog may be helpful.

EMP
  • 59,148
  • 53
  • 164
  • 220