[thelist] Javascript: OK? Cancel!

Edwin Martin e.j.martin at chello.nl
Thu Feb 14 06:17:01 CST 2002


Hi Douglas Williams, at 05:44 14-2-2002 -0600 you wrote:
>try this...
>
>if (confirm('Are you sure?'))
>{
>     do form submit here
>}
>
>Just stick that in the function and call it from onSubmit or however you
>want to call it.

Why not really short:

<form onSubmit="return confirm('Are you sure?')" action="myAction"
method="post">...

Works in every browser.

Bye,
Edwin Martin



>----- Original Message -----
>From: "Frank" <framar at interlog.com>
>To: <thelist at lists.evolt.org>
>Sent: Thursday, February 14, 2002 5:33 AM
>Subject: [thelist] Javascript: OK? Cancel!
>
>
> >
> > Dunno if this can be done - I want to pop up a javascript alert with
> > an 'OK' and 'Cancel' button. Of course the cancel button lets the
> > page just kinda sit there, whereas 'OK' proceeds to submit the form.
> >
> > I know the functionality is doable - but is the dialogue box?
> > --
> >
> > Our best destiny, as planetary cohabitants, is the development
> > of what has been called "species consciousness" - something over
> > and above nationalisms, blocs, religions, ethnicities.
> >
> >
> > Frank Marion                      Framar Studios
> > frank at framarstudios.com           http://www.framarstudios.com
> > --
> > For unsubscribe and other options, including
> > the Tip Harvester and archive of thelist go to:
> > http://lists.evolt.org Workers of the Web, evolt !
> >
>
>--
>For unsubscribe and other options, including
>the Tip Harvester and archive of thelist go to:
>http://lists.evolt.org Workers of the Web, evolt !
---
Surf Edwin Martin's brainwaves: http://www.bitstorm.org/edwin/





More information about the thelist mailing list