SAPO::Widget.Dialog->confirm

This method will show a confirm window with a message, an OK button and a CANCEL button

This is a static method.

Syntax

SAPO.Widget.Dialog.confirm(string, <optional image src to OK button>, <optional image src to CANCEL button> ,<optional options>);

Compatibility

All browsersYes

Depends

Input Parameters

  • (string) string : Message string
  • (string) string : Image URI string or false
  • (string) string : Image URI string or false
  • (object) options : Optional options

Options

  • width: (int) window width (default: 250)
  • height: (int) window height
  • onComplete: (function) Function to call after show confirm window
  • callBack: (function) Function to call when OK button is clicked
  • callBackCancel: (function) Function to call when CANCEL button is clicked
  • className: (string) CSS class to style alert box

Sample

 http://js.sapo.pt/SAPO/Widget/Dialog/sample/

Example

SAPO.Widget.Dialog.alert('This is a message\n\nSecond line', false, false, {callBack:function(){ alert('My OK callBack'); }, callBackCancel:function(){ alert('My CANCEL callBack'); }});


Community feedback

Error: Failed to load processor AddComment
No macro or processor named 'AddComment' found