Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 224
  • Last Modified:

Change caption of alert box

Is it possible to change the caption of an alert box in ASP from 'Microsoft Interner Explorer' to some other caption like 'My application error'?
0
RSujathaRaman
Asked:
RSujathaRaman
3 Solutions
 
GaryCommented:
No
0
 
cj_nepentheCommented:

Hi,

Unfortunately not, this is by design as a security precaution.
However it is possible to design your own error window, then display it using the window.showModalDialog() function.

See here for details:
http://msdn.microsoft.com/workshop/author/dhtml/reference/methods/showmodaldialog.asp

This will also allow you set your own window title, although the text "Web Page Dialog" will always be displayed next to it for security.  A modal dialog box must be closed before the user can return to the page, so it behaves in the same was as an alert() window.

Good luck!
0
 
mmarksburyCommented:
Why not create a custom <DIV> element that displays instead of the alert box?  This way you can make it look exactly the way you want and not be confined to the limitations of the alert box.  It would be considerable more coding, but once it is done, you can use it on any page easily.  Good luck!
0
 
masirofCommented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned..
I will leave the following recommendation for this question in the Cleanup topic area:
Split: GaryC123 & cj_nepenthe & mmarksbury

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

masirof
EE Cleanup Volunteer
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now