hwg-basics archives | Apr 2000 | new search | results | previous | next |
Re: Yes/No popup box with Javascriptby "Comharsa" <comharsa(at)clara.net> |
|
> Does anybody know if it's possible to pop up a small "are you sure?" > messagebox that will have a "yes" and "no" button on it? > > Thanks, > Raj. Yes, it is. The following would do it. <input type="button" value="Submit" onclick="temp = window.confirm('Are you sure?');"> The two options on the confirm dialogue wil be OK and Cancel. These return a value of true or false to the variable "temp" in the example above, which you could then use to decide whether something else happens.. HTH Brian comharsa(at)clara.net
HTML: hwg-basics mailing list archives, maintained by Webmasters @ IWA