Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #13024 > unrolled thread

Preventing "Prevent this page from creating additional dialogs"

Started by"Larry.Martell@gmail.com" <larry.martell@gmail.com>
First post2012-03-23 17:12 -0700
Last post2012-04-03 22:06 +1000
Articles 20 on this page of 44 — 15 participants

Back to article view | Back to comp.lang.javascript


Contents

  Preventing "Prevent this page from creating additional dialogs" "Larry.Martell@gmail.com" <larry.martell@gmail.com> - 2012-03-23 17:12 -0700
    Re: Preventing "Prevent this page from creating additional dialogs" Scott Johnson <noonehome@chalupasworld.com> - 2012-03-24 06:55 -0700
      Re: Preventing "Prevent this page from creating additional dialogs" "Larry.Martell@gmail.com" <larry.martell@gmail.com> - 2012-03-24 07:58 -0700
        Re: Preventing "Prevent this page from creating additional dialogs" Denis McMahon <denismfmcmahon@gmail.com> - 2012-03-24 18:41 +0000
        Re: Preventing "Prevent this page from creating additional dialogs" Scott Johnson <noonehome@chalupasworld.com> - 2012-03-24 20:59 -0700
        Re: Preventing "Prevent this page from creating additional dialogs" "Larry.Martell@gmail.com" <larry.martell@gmail.com> - 2012-03-25 12:26 -0700
          Re: Preventing "Prevent this page from creating additional dialogs" Scott Johnson <noonehome@chalupasworld.com> - 2012-03-25 16:55 -0700
    Re: Preventing "Prevent this page from creating additional dialogs" "Tom de Neef" <tdeneef@qolor.nl> - 2012-03-24 17:06 +0100
    Re: Preventing "Prevent this page from creating additional dialogs" Rick Viscomi <rviscomi@gmail.com> - 2012-03-24 11:24 -0700
      Re: Preventing "Prevent this page from creating additional dialogs" Scott Johnson <noonehome@chalupasworld.com> - 2012-03-24 21:01 -0700
      Re: Preventing "Prevent this page from creating additional dialogs" David Mark <dmark.cinsoft@gmail.com> - 2012-03-28 20:16 -0700
        Re: Preventing "Prevent this page from creating additional dialogs" Matt McDonald <matt@fortybelow.ca> - 2012-04-03 08:35 -0600
      Re: Preventing "Prevent this page from creating additional dialogs" theAbacus@yahoo.com - 2012-04-02 16:16 -0700
        Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-02 21:11 -0700
          Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-03 07:01 +0000
            Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-03 08:28 -0700
          Re: Preventing "Prevent this page from creating additional dialogs" Jeff North <jnorthau@yahoo.com.au> - 2012-04-03 17:20 +1000
          Re: Preventing "Prevent this page from creating additional dialogs" David Mark <dmark.cinsoft@gmail.com> - 2012-04-03 00:28 -0700
            Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-03 11:24 +0000
              Re: Preventing "Prevent this page from creating additional dialogs" Dr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid> - 2012-04-04 21:13 +0100
                Re: Preventing "Prevent this page from creating additional dialogs" Jeff North <jnorthau@yahoo.com.au> - 2012-04-05 14:12 +1000
                  Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-05 08:12 +0000
                    Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-05 08:51 -0700
                      Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-05 22:37 +0000
                        Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-05 19:51 -0700
                          Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-06 07:22 +0000
                            Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-06 09:14 -0700
                              Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-06 19:54 +0000
                                Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-06 13:09 -0700
                                  Re: Preventing "Prevent this page from creating additional dialogs" "Evertjan." <exjxw.hannivoort@interxnl.net> - 2012-04-06 20:23 +0000
                                    Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-06 19:48 -0700
                                  Re: Preventing "Prevent this page from creating additional dialogs" Dr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid> - 2012-04-07 19:14 +0100
                          Re: Preventing "Prevent this page from creating additional dialogs" Dr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid> - 2012-04-07 19:04 +0100
                      Re: Preventing "Prevent this page from creating additional dialogs" Dr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid> - 2012-04-06 21:20 +0100
                        Re: Preventing "Prevent this page from creating additional dialogs" Eric Bednarz <bednarz@fahr-zur-hoelle.org> - 2012-04-07 02:49 +0200
                          Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-06 19:49 -0700
                            Re: Preventing "Prevent this page from creating additional dialogs" Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-04-07 03:02 +0000
                              Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-06 20:38 -0700
                                Re: Preventing "Prevent this page from creating additional dialogs" Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-04-07 04:09 +0000
                                  Re: Preventing "Prevent this page from creating additional dialogs" Dr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid> - 2012-04-08 19:34 +0100
                                    Re: Preventing "Prevent this page from creating additional dialogs" Mike Duffy <Use_guestbook_page@website.in.sig> - 2012-04-09 14:56 +0000
                              Re: Preventing "Prevent this page from creating additional dialogs" John G Harris <john@nospam.demon.co.uk> - 2012-04-07 11:38 +0100
            Re: Preventing "Prevent this page from creating additional dialogs" Gene Wirchenko <genew@ocis.net> - 2012-04-03 08:37 -0700
        Re: Preventing "Prevent this page from creating additional dialogs" Jeff North <jnorthau@yahoo.com.au> - 2012-04-03 22:06 +1000

Page 1 of 3  [1] 2 3  Next page →


#13024 — Preventing "Prevent this page from creating additional dialogs"

From"Larry.Martell@gmail.com" <larry.martell@gmail.com>
Date2012-03-23 17:12 -0700
SubjectPreventing "Prevent this page from creating additional dialogs"
Message-ID<8c8ded8c-6649-4772-a5fc-470348bc14d7@s9g2000pba.googlegroups.com>
I have an alert that is displayed on an error. The second time the
alert is displayed, it comes up with a checkbox that says "Prevent
this page from creating additional dialogs". If this is checked the
alert no longer gets displayed. How can I prevent that message so that
the alert is always displayed?

[toc] | [next] | [standalone]


#13040

FromScott Johnson <noonehome@chalupasworld.com>
Date2012-03-24 06:55 -0700
Message-ID<jkkjou$2k5$1@dont-email.me>
In reply to#13024
On 3/23/2012 5:12 PM, Larry.Martell@gmail.com wrote:
> I have an alert that is displayed on an error. The second time the
> alert is displayed, it comes up with a checkbox that says "Prevent
> this page from creating additional dialogs". If this is checked the
> alert no longer gets displayed. How can I prevent that message so that
> the alert is always displayed?

Tip: don't check the box!

First off not sure you can or should, that would be a browser security 
feature.

Secondly, why would you want to?
If you are only using it to display error messages (which I doubt), then 
the extra line is pretty inconsequential and the data is still visible.
If you are trying to circumvent the clients no-popup wishes, well then 
'bye-bye'.

[toc] | [prev] | [next] | [standalone]


#13041

From"Larry.Martell@gmail.com" <larry.martell@gmail.com>
Date2012-03-24 07:58 -0700
Message-ID<2adf9a2e-fcd9-4e23-a102-9d541a02c551@px4g2000pbc.googlegroups.com>
In reply to#13040
On Mar 24, 7:55 am, Scott Johnson <nooneh...@chalupasworld.com> wrote:
> On 3/23/2012 5:12 PM, Larry.Mart...@gmail.com wrote:
>
> > I have an alert that is displayed on an error. The second time the
> > alert is displayed, it comes up with a checkbox that says "Prevent
> > this page from creating additional dialogs". If this is checked the
> > alert no longer gets displayed. How can I prevent that message so that
> > the alert is always displayed?
>
> Tip: don't check the box!

I can't control what the user does.

>
> First off not sure you can or should, that would be a browser security
> feature.
>
> Secondly, why would you want to?

This is an internal app, and this is what the client I work for wants.

> If you are only using it to display error messages (which I doubt), then
> the extra line is pretty inconsequential and the data is still visible.

I don't really care about the alert, but I have a onkeyup event that
checks their input in a text field. If they enter something invalid,
the alert tells then, and then when they dismiss it, it removes the
offending character from the text field. Once they check the "Prevent
this page from creating additional dialogs" box, it seems my event
handler doesn't get called any more, cause the offending character
stops getting removed. If I could get that to still happen, I'd be OK
with the alert not showing.


> If you are trying to circumvent the clients no-popup wishes, well then
> 'bye-bye'.

The client is who is asking for this.

[toc] | [prev] | [next] | [standalone]


#13045

FromDenis McMahon <denismfmcmahon@gmail.com>
Date2012-03-24 18:41 +0000
Message-ID<4f6e154d$0$2782$a8266bb1@newsreader.readnews.com>
In reply to#13041
On Sat, 24 Mar 2012 07:58:07 -0700, Larry.Martell@gmail.com wrote:

> On Mar 24, 7:55 am, Scott Johnson <nooneh...@chalupasworld.com> wrote:
>> On 3/23/2012 5:12 PM, Larry.Mart...@gmail.com wrote:
>>
>> > I have an alert that is displayed on an error. The second time the
>> > alert is displayed, it comes up with a checkbox that says "Prevent
>> > this page from creating additional dialogs". If this is checked the
>> > alert no longer gets displayed. How can I prevent that message so
>> > that the alert is always displayed?
>>
>> Tip: don't check the box!
> 
> I can't control what the user does.
> 
> 
>> First off not sure you can or should, that would be a browser security
>> feature.
>>
>> Secondly, why would you want to?
> 
> This is an internal app, and this is what the client I work for wants.
> 
>> If you are only using it to display error messages (which I doubt),
>> then the extra line is pretty inconsequential and the data is still
>> visible.
> 
> I don't really care about the alert, but I have a onkeyup event that
> checks their input in a text field. If they enter something invalid, the
> alert tells then, and then when they dismiss it, it removes the
> offending character from the text field. Once they check the "Prevent
> this page from creating additional dialogs" box, it seems my event
> handler doesn't get called any more, cause the offending character stops
> getting removed. If I could get that to still happen, I'd be OK with the
> alert not showing.
> 
> 
>> If you are trying to circumvent the clients no-popup wishes, well then
>> 'bye-bye'.
> 
> The client is who is asking for this.

In this context, the "client" or "user" is the person whose web browser 
is rendering your server delivered content. Not the customer who is 
paying you to develop that content.

The only solution is for your customer to commision a modified browser 
build and roll that out to his users.

Basically you're asking to disable a browser security feature. Browser 
security features aren't meant to be disabled by content delivered from 
the server, they're meant to be wholly under the control of the person 
(user) on whose computer the "client" browser process is running.

If you do figure out a way to disable a browser security feature, you 
should enter into one of those competitions where people get prizes of 
several tens of thousands of dollars for showing browser coders where 
there are security holes in their browser!

Point out to your "customer" that the feature he is asking for can only 
be delivered by a customised browser build, you'll need to start with a 
browser whose source code is available under something like GPL, and if 
his "internal" users then use the modified browser to access external 
websites, they will be at an extremely high risk of getting hit by all 
sorts of exploits unless he employs someone on an ongoing basis to 
rebuild and roll out a new custom build every time a security patch gets 
applied in the upstream source.

Rgds

Denis McMahon

[toc] | [prev] | [next] | [standalone]


#13048

FromScott Johnson <noonehome@chalupasworld.com>
Date2012-03-24 20:59 -0700
Message-ID<jkm57c$82c$1@dont-email.me>
In reply to#13041
On 3/24/2012 7:58 AM, Larry.Martell@gmail.com wrote:
> On Mar 24, 7:55 am, Scott Johnson<nooneh...@chalupasworld.com>  wrote:
>> On 3/23/2012 5:12 PM, Larry.Mart...@gmail.com wrote:
>>
>>> I have an alert that is displayed on an error. The second time the
>>> alert is displayed, it comes up with a checkbox that says "Prevent
>>> this page from creating additional dialogs". If this is checked the
>>> alert no longer gets displayed. How can I prevent that message so that
>>> the alert is always displayed?
>>
>> Tip: don't check the box!
>
> I can't control what the user does.
>
>>
>> First off not sure you can or should, that would be a browser security
>> feature.
>>
>> Secondly, why would you want to?
>
> This is an internal app, and this is what the client I work for wants.
>
>> If you are only using it to display error messages (which I doubt), then
>> the extra line is pretty inconsequential and the data is still visible.
>
> I don't really care about the alert, but I have a onkeyup event that
> checks their input in a text field. If they enter something invalid,
> the alert tells then, and then when they dismiss it, it removes the
> offending character from the text field. Once they check the "Prevent
> this page from creating additional dialogs" box, it seems my event
> handler doesn't get called any more, cause the offending character
> stops getting removed. If I could get that to still happen, I'd be OK
> with the alert not showing.
>

You are using the wrong tool for alerting the client (browser user) that 
there was a validation error.  If you are validating the field in real 
time them set up a notice box and then use innerhtml to push the messages.
Something as simple as an empty DIV will work and then you can style it 
also.

>
>> If you are trying to circumvent the clients no-popup wishes, well then
>> 'bye-bye'.
>
> The client is who is asking for this.

[toc] | [prev] | [next] | [standalone]


#13059

From"Larry.Martell@gmail.com" <larry.martell@gmail.com>
Date2012-03-25 12:26 -0700
Message-ID<9a0d6a58-151b-4ce7-96db-af7eee7cb5ea@pz2g2000pbc.googlegroups.com>
In reply to#13041
On Mar 24, 8:58 am, "Larry.Mart...@gmail.com"
<larry.mart...@gmail.com> wrote:
> On Mar 24, 7:55 am, Scott Johnson <nooneh...@chalupasworld.com> wrote:
>
> > On 3/23/2012 5:12 PM, Larry.Mart...@gmail.com wrote:
>
> > > I have an alert that is displayed on an error. The second time the
> > > alert is displayed, it comes up with a checkbox that says "Prevent
> > > this page from creating additional dialogs". If this is checked the
> > > alert no longer gets displayed. How can I prevent that message so that
> > > the alert is always displayed?
>
> > Tip: don't check the box!
>
> I can't control what the user does.
>
>
>
> > First off not sure you can or should, that would be a browser security
> > feature.
>
> > Secondly, why would you want to?
>
> This is an internal app, and this is what the client I work for wants.
>
> > If you are only using it to display error messages (which I doubt), then
> > the extra line is pretty inconsequential and the data is still visible.
>
> I don't really care about the alert, but I have a onkeyup event that
> checks their input in a text field. If they enter something invalid,
> the alert tells then, and then when they dismiss it, it removes the
> offending character from the text field. Once they check the "Prevent
> this page from creating additional dialogs" box, it seems my event
> handler doesn't get called any more, cause the offending character
> stops getting removed. If I could get that to still happen, I'd be OK
> with the alert not showing.

I figured out was was going on here. Once the "Prevent this page from
creating additional dialogs" was checked, then the alert() was
throwing an exception. That's what was preventing the rest of my
onkeyup event handler from running. Once I put it in a try/catch the
rest of the event handler still ran. That's what's really important,
so I don't need to worry about this any more.

[toc] | [prev] | [next] | [standalone]


#13061

FromScott Johnson <noonehome@chalupasworld.com>
Date2012-03-25 16:55 -0700
Message-ID<jkoba9$c3h$1@dont-email.me>
In reply to#13059
On 3/25/2012 12:26 PM, Larry.Martell@gmail.com wrote:
> On Mar 24, 8:58 am, "Larry.Mart...@gmail.com"
> <larry.mart...@gmail.com>  wrote:
>> On Mar 24, 7:55 am, Scott Johnson<nooneh...@chalupasworld.com>  wrote:
>>
>>> On 3/23/2012 5:12 PM, Larry.Mart...@gmail.com wrote:
>>
>>>> I have an alert that is displayed on an error. The second time the
>>>> alert is displayed, it comes up with a checkbox that says "Prevent
>>>> this page from creating additional dialogs". If this is checked the
>>>> alert no longer gets displayed. How can I prevent that message so that
>>>> the alert is always displayed?
>>
>>> Tip: don't check the box!
>>
>> I can't control what the user does.
>>
>>
>>
>>> First off not sure you can or should, that would be a browser security
>>> feature.
>>
>>> Secondly, why would you want to?
>>
>> This is an internal app, and this is what the client I work for wants.
>>
>>> If you are only using it to display error messages (which I doubt), then
>>> the extra line is pretty inconsequential and the data is still visible.
>>
>> I don't really care about the alert, but I have a onkeyup event that
>> checks their input in a text field. If they enter something invalid,
>> the alert tells then, and then when they dismiss it, it removes the
>> offending character from the text field. Once they check the "Prevent
>> this page from creating additional dialogs" box, it seems my event
>> handler doesn't get called any more, cause the offending character
>> stops getting removed. If I could get that to still happen, I'd be OK
>> with the alert not showing.
>
> I figured out was was going on here. Once the "Prevent this page from
> creating additional dialogs" was checked, then the alert() was
> throwing an exception. That's what was preventing the rest of my
> onkeyup event handler from running. Once I put it in a try/catch the
> rest of the event handler still ran. That's what's really important,
> so I don't need to worry about this any more.

Good catch.

I have never used the alert for client side use so I was not even sure 
how you would continue the script without it being clicked.  Now I know.

Scotty

[toc] | [prev] | [next] | [standalone]


#13042

From"Tom de Neef" <tdeneef@qolor.nl>
Date2012-03-24 17:06 +0100
Message-ID<4f6df10a$0$6989$e4fe514c@news2.news.xs4all.nl>
In reply to#13024
"Larry.Martell@gmail.com" <larry.martell@gmail.com> schreef in bericht 
news:8c8ded8c-6649-4772-a5fc-470348bc14d7@s9g2000pba.googlegroups.com...
>I have an alert that is displayed on an error. The second time the
> alert is displayed, it comes up with a checkbox that says "Prevent
> this page from creating additional dialogs". If this is checked the
> alert no longer gets displayed. How can I prevent that message so that
> the alert is always displayed?

Will all other alerts be prevented or just the one with the same message. In 
the latter case: modify the message by appending a hidden random number.
Tom 

[toc] | [prev] | [next] | [standalone]


#13044

FromRick Viscomi <rviscomi@gmail.com>
Date2012-03-24 11:24 -0700
Message-ID<10806346.32.1332613472484.JavaMail.geo-discussion-forums@vbht7>
In reply to#13024
On Friday, March 23, 2012 8:12:00 PM UTC-4, Larry....@gmail.com wrote:
> I have an alert that is displayed on an error. The second time the
> alert is displayed, it comes up with a checkbox that says "Prevent
> this page from creating additional dialogs". If this is checked the
> alert no longer gets displayed. How can I prevent that message so that
> the alert is always displayed?

The solution is to not use alerts. Use a popup div, which also gives you style control for browser consistency.

[toc] | [prev] | [next] | [standalone]


#13049

FromScott Johnson <noonehome@chalupasworld.com>
Date2012-03-24 21:01 -0700
Message-ID<jkm5ai$82c$2@dont-email.me>
In reply to#13044
On 3/24/2012 11:24 AM, Rick Viscomi wrote:
> On Friday, March 23, 2012 8:12:00 PM UTC-4, Larry....@gmail.com wrote:
>> I have an alert that is displayed on an error. The second time the
>> alert is displayed, it comes up with a checkbox that says "Prevent
>> this page from creating additional dialogs". If this is checked the
>> alert no longer gets displayed. How can I prevent that message so that
>> the alert is always displayed?
>
> The solution is to not use alerts. Use a popup div, which also gives you style control for browser consistency.

Woops did not see this before I responded. Beesknees!

[toc] | [prev] | [next] | [standalone]


#13155

FromDavid Mark <dmark.cinsoft@gmail.com>
Date2012-03-28 20:16 -0700
Message-ID<15672b55-0edf-441b-9592-5317b393fabf@k6g2000vbz.googlegroups.com>
In reply to#13044
On Mar 24, 2:24 pm, Rick Viscomi <rvisc...@gmail.com> wrote:
> On Friday, March 23, 2012 8:12:00 PM UTC-4, Larry....@gmail.com wrote:
> > I have an alert that is displayed on an error. The second time the
> > alert is displayed, it comes up with a checkbox that says "Prevent
> > this page from creating additional dialogs". If this is checked the
> > alert no longer gets displayed. How can I prevent that message so that
> > the alert is always displayed?
>
> The solution is to not use alerts. Use a popup div, which also gives you style control for browser consistency.

Browser consistency?  An alert will look exactly as the user of a
specific browser expects.  It won't appear off the screen or require a
lot of complicated script to work in cross-browser fashion.  Jumping
through hoops just to style it to look like something other than an
alert seems counterproductive.

Best to avoid overlapping pop-ups of any kind when possible (certainly
the case with validation functions).

[toc] | [prev] | [next] | [standalone]


#13193

FromMatt McDonald <matt@fortybelow.ca>
Date2012-04-03 08:35 -0600
Message-ID<jlf1rk$60d$1@dont-email.me>
In reply to#13155
On 12-03-28 09:16 PM, David Mark wrote:
> Best to avoid overlapping pop-ups of any kind when possible (certainly
> the case with validation functions).

I've had problems with Opera (Linux Mint) recently regarding
overlapping dialogs. I have per-cookie monitoring set, which
yields a prompt for every single cookie. Sometimes an unexpected
cookie will be "prompted" while I'm about to switch tabs (via
ctrl + tab). When I change tabs, the expected modal "dialog"
comes up, except underneath the cookie "prompt". This causes
Opera to lock up every time without fail.

-- 
Matt McDonald: Web/Flash Developer; Edmonton, Alberta, Canada

[toc] | [prev] | [next] | [standalone]


#13182

FromtheAbacus@yahoo.com
Date2012-04-02 16:16 -0700
Message-ID<30433830.1107.1333408583298.JavaMail.geo-discussion-forums@yneo2>
In reply to#13044
A popUp div seems like a reasonable solution; but when this popUp div appears on the screen & the User clicks outside the popUp div, then isn't the popUp simply minimized?  (You could use an onblur window.close(), but is that desirable?)

And once the popUp div is minimized, any subsequent calls to the popUp div will not cause the new/next popUp div to appear on the User's screen  because it's already minimized?

A valuable aspect of "alert();" is that it is modal(?), i.e. requires User response before resuming app execution.

popUp div's and/or perhaps a little piece of the screen's "real estate" being dedicated to error msgs (& the like) provide some degree of User interaction; but they don't have the impact of an "alert" or "confirm" or "prompt" box.



On Saturday, March 24, 2012 1:24:32 PM UTC-5, Rick Viscomi wrote:
> On Friday, March 23, 2012 8:12:00 PM UTC-4, Larry....@gmail.com wrote:
> > I have an alert that is displayed on an error. The second time the
> > alert is displayed, it comes up with a checkbox that says "Prevent
> > this page from creating additional dialogs". If this is checked the
> > alert no longer gets displayed. How can I prevent that message so that
> > the alert is always displayed?
> 
> The solution is to not use alerts. Use a popup div, which also gives you style control for browser consistency.

[toc] | [prev] | [next] | [standalone]


#13185

FromGene Wirchenko <genew@ocis.net>
Date2012-04-02 21:11 -0700
Message-ID<oqtkn75udl38ibkrr4vmuh03klujkdj7bq@4ax.com>
In reply to#13182
On Mon, 2 Apr 2012 16:16:23 -0700 (PDT), theAbacus@yahoo.com wrote:

[snip]

>A valuable aspect of "alert();" is that it is modal(?), i.e. requires User response before resuming app execution.

     An unvaluable aspect of alert() is that the button captions are
often inappropriate.  I am looking at having a Cancel button for a
form and wish to have it confirmed.  Unfortunately,
          fChoice=alert("Really cancel?");
has issues.  (Which button should confirm the cancellation, and which
should cancel the cancellation?)

[snip]

Sincerely,

Gene Wirchenko

[toc] | [prev] | [next] | [standalone]


#13186

From"Evertjan." <exjxw.hannivoort@interxnl.net>
Date2012-04-03 07:01 +0000
Message-ID<XnsA02A5BBD12BC9eejj99@194.109.133.133>
In reply to#13185
Gene Wirchenko wrote on 03 apr 2012 in comp.lang.javascript:

> On Mon, 2 Apr 2012 16:16:23 -0700 (PDT), theAbacus@yahoo.com wrote:
> 
> [snip]
> 
>>A valuable aspect of "alert();" is that it is modal(?), i.e. requires
>>User response before resuming app execution. 
> 
>      An unvaluable aspect of alert() is that the button captions are
> often inappropriate.  I am looking at having a Cancel button for a
> form and wish to have it confirmed.  Unfortunately,
>           fChoice=alert("Really cancel?");
> has issues.  (Which button should confirm the cancellation, and which
> should cancel the cancellation?)

alert(); has only one button.

Methinks you are not talking about alert(); but about confirm();  

The problem with these button texts is, 
that they use the language of the operating system settings.

var choice = confirm("Really cancel?");

is only understandable in certain OS language settings,
even where the page language is English.

See:
<http://hannivoort.org/test/confirmChromeDutch.jpg>

-- 
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

[toc] | [prev] | [next] | [standalone]


#13194

FromGene Wirchenko <genew@ocis.net>
Date2012-04-03 08:28 -0700
Message-ID<3n5mn7pue3l7mps4s5gj418r2i66a54v67@4ax.com>
In reply to#13186
On 03 Apr 2012 07:01:07 GMT, "Evertjan."
<exjxw.hannivoort@interxnl.net> wrote:

[snip]

>alert(); has only one button.
>
>Methinks you are not talking about alert(); but about confirm();  

     Quite.  Sorry for the error, folks.

[snip]

Sincerely,

Gene Wirchenko

[toc] | [prev] | [next] | [standalone]


#13187

FromJeff North <jnorthau@yahoo.com.au>
Date2012-04-03 17:20 +1000
Message-ID<539ln71gkg40itlrur2k8pvm7qrusvgide@4ax.com>
In reply to#13185
On Mon, 02 Apr 2012 21:11:16 -0700, in comp.lang.javascript Gene
Wirchenko <genew@ocis.net>
<oqtkn75udl38ibkrr4vmuh03klujkdj7bq@4ax.com> wrote:

>| On Mon, 2 Apr 2012 16:16:23 -0700 (PDT), theAbacus@yahoo.com wrote:
>| 
>| [snip]
>| 
>| >A valuable aspect of "alert();" is that it is modal(?), i.e. requires User response before resuming app execution.
>| 
>|      An unvaluable aspect of alert() is that the button captions are
>| often inappropriate.  I am looking at having a Cancel button for a
>| form and wish to have it confirmed.  Unfortunately,
>|           fChoice=alert("Really cancel?");
>| has issues.  (Which button should confirm the cancellation, and which
>| should cancel the cancellation?)
>| 
>| [snip]

That is why there is a confirm(message) window method.

[toc] | [prev] | [next] | [standalone]


#13188

FromDavid Mark <dmark.cinsoft@gmail.com>
Date2012-04-03 00:28 -0700
Message-ID<9fd2696f-740d-4b55-a75b-43383e903047@b3g2000yqb.googlegroups.com>
In reply to#13185
On Apr 3, 12:11 am, Gene Wirchenko <ge...@ocis.net> wrote:
> On Mon, 2 Apr 2012 16:16:23 -0700 (PDT), theAba...@yahoo.com wrote:
>
> [snip]
>
> >A valuable aspect of "alert();" is that it is modal(?), i.e. requires User response before resuming app execution.
>
>      An unvaluable aspect of alert() is that the button captions are
> often inappropriate.  I am looking at having a Cancel button for a
> form and wish to have it confirmed.  Unfortunately,
>           fChoice=alert("Really cancel?");
> has issues.  (Which button should confirm the cancellation, and which
> should cancel the cancellation?)
>

As mentioned, you've got hold of a - confirm - there.  And with OK/
Cancel you make statements (e.g. You will lose your unsaved data).
Questions are for Yes/No dialogs.  OK/Cancel is what browsers use, so
deal with it.

[toc] | [prev] | [next] | [standalone]


#13189

From"Evertjan." <exjxw.hannivoort@interxnl.net>
Date2012-04-03 11:24 +0000
Message-ID<XnsA02A88568F72Eeejj99@194.109.133.133>
In reply to#13188
David Mark wrote on 03 apr 2012 in comp.lang.javascript:

> OK/Cancel is what browsers use, so
> deal with it.

Only with the OS set to English.


-- 
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

[toc] | [prev] | [next] | [standalone]


#13222

FromDr J R Stockton <reply1214@merlyn.demon.co.uk.not.invalid>
Date2012-04-04 21:13 +0100
Message-ID<xcijeeTNtKfPFw4E@invalid.uk.co.demon.merlyn.invalid>
In reply to#13189
In comp.lang.javascript message <XnsA02A88568F72Eeejj99@194.109.133.133>
, Tue, 3 Apr 2012 11:24:10, Evertjan. <exjxw.hannivoort@interxnl.net>
posted:

>David Mark wrote on 03 apr 2012 in comp.lang.javascript:
>
>> OK/Cancel is what browsers use, so
>> deal with it.
>
>Only with the OS set to English.

<http://www.merlyn.demon.co.uk/quotings.htm#FredHoyle> : it's worked
with you.


What is needed is a General Asker.

        window.asker = function(A, B, C, D, E, F) { native code }

A is an array of strings to show above, between, and under B & C.
B is an array of strings to  label  input type=text elements
C is an array of strings to preload input type=text elements
D is an array of button legends.
E is an array with E[0] being the number of the default button
F is a number indexing into standard icons such as Error, Warn; or a
reference to an image to be used; or empty.

The return value is an array corresponding to C but as altered, and E[0]
is now the number of the button pressed (with the close box being -1).

Or something equally general - one might use colours, too.

-- 
 (c) John Stockton, nr London, UK. ?@merlyn.demon.co.uk  Turnpike v6.05  MIME.
  Web  <http://www.merlyn.demon.co.uk/> - FAQqish topics, acronyms and links;
  Astro stuff via astron-1.htm, gravity0.htm ; quotings.htm, pascal.htm, etc.
 No Encoding. Quotes before replies. Snip well. Write clearly. Don't Mail News.

[toc] | [prev] | [next] | [standalone]


Page 1 of 3  [1] 2 3  Next page →

Back to top | Article view | comp.lang.javascript


csiph-web