[whatwg] Can we deprecate alert(), confirm(), prompt() ?
ash at ashleysheridan.co.uk
Thu Nov 25 04:41:14 PST 2010
Code their site for speech browsers? Seriously?!
----- Reply message -----
From: "Biju" <bijumaillist at gmail.com>
Date: Thu, Nov 25, 2010 12:21
Subject: [whatwg] Can we deprecate alert(), confirm(), prompt() ?
To: <whatwg at lists.whatwg.org>
On Thu, Nov 25, 2010 at 3:30 AM, Nils Dagsson Moskopp
>> 1. Can we deprecate alert(), confirm(), prompt() ?
> If sites rely on them, it is not possible to deprecate them.
That is why I asked to deprecate, but not obsolete..
> However, I melieve browsers are making these dialogs tab-modal.
Yes I know but still there are problems
(I assume that will be fixed)
But see also https://bugzilla.mozilla.org/show_bug.cgi?id=391834
>> 2. if we are still keeping them, can we disable them in
>> onbeforeunload/onunload[/onhide] etc. Many sites add extra dialogs in
>> those events to confuse users, so that they can trap users for little
> “Do you want to save your complicated mashup?”
For that we dont need alert/confirm/prompt.
Return value in onbeforeunload will take care of it
You may want to also look Jesse Ruderman suggestion on that
>> 3. also if we are keeping them, can we add an optional parameter for a
>> timeout milliseconds to self dismiss the modal prompt.
> Why would you need that?
This is especially useful with alert()
In a software application there is no need to have prompt to the user
if the application is not planning to do any branching after user
When we have alert(), it dont give user any choice other than pressing OK
Hence it not possible to code any branching statement after result of
user action. (with exception "Press OK after you insert DVD to the
So only use for alert() I see is not make a delay, that use case can
be improved if web programmer can provide a default time out.
On Thu, Nov 25, 2010 at 3:41 AM, ash at ashleysheridan.co.uk
<ash at ashleysheridan.co.uk> wrote:
> Modal dialogues have a very special purpose, which works consistently across
> specific responses. What would happen if someone came to your site with a
> speech/Braille browser? How would they know your pretty js lib built
That is a valid point. But how many good sites use
alert/confirm/prompt for every thing. So all those case speech/Braille
browser have problem to deal with.
If we want use that feature the web site need to code their site for
speech/Braille browser. If that is the case we could achieve same
thing with HTML.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the whatwg