Define title of alert box, HTML, Javascript

Posted on 2007-07-30
Last Modified: 2008-01-09

I am using the <body bgcolor="white" text="black" onload="alert('Hello!')"> tag and would like to also define the title of the alert box. Currently the title comes up as "Windows Internet Explorer"

Can this be done?
Question by:webkiwi1
    LVL 15

    Accepted Solution

    No.  If you use the built-in alert box, you can't change the title.

    A workable alternative is to build you own display box, so you can set the title.  You can find complete code for doing this here:

    Author Comment

    Got it, thanks for the reply. Not sure if I will go that route but may stick with the existing "boring" alert!!!
    LVL 7

    Expert Comment


    Found this on some other forum:

    What you could do is open a pop up (html side) and chage title as you wish.

    Tell me if this is acceptable.


    Featured Post

    Training Course: Adobe Photoshop CC 2015

    Photoshop has become the standard in image manipulation among professional photographers and graphic designers. This course covers exam objectives for the Adobe Certified Associate (ACA) certification.

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    json example 39 78
    Add json string to a javascript object 9 34
    PHP foreach DB query 4 21
    Align a <div> to a table row 3 20
    Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
    Envision that you are chipping away at another e-business site with a team of pundit developers and designers. Everything seems, by all accounts, to be going easily.
    The viewer will learn how to dynamically set the form action using jQuery.
    The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now