Confirm box
var r = confirm("Press a button!"); if (r == true) { "You pressed OK!"; } else { "You pressed Cancel!"; }