simpleDialog

simpleDialog

Hi, i want to use a simple Dialog with JQM, i got an example from  here  unfortunally it doesn't work !!!, here is what i want to do:
     
gestion.js
  1. function closeSupprimerDialog(id){
  2. alert(id); // i got id here
  3. $(document).delegate('#confirmationSupprimerOffre', 'click', function() {
  4.   $(this).simpledialog({
  5.    'mode' : 'bool',
  6.    'prompt' : 'Confirmation',
  7.    'useModal' : true,
  8.    'buttons' : {
  9.       'Delete': {
  10.       click: function () {
  11.         $('#confirmationSupprimerOffre').text('delete');
  12.         }
  13.     },
  14.     'Cancel': {
  15.         click: function () {
  16.         $('#confirmationSupprimerOffre').text('cancel');
  17.         },
  18.         icon: "delete",
  19.         theme: "c"
  20.       }
  21.    }
  22.  })
  23. }
  24. }
 gestion.htm
        
  1.      
  2.                 <div data-role="popup" id="confirmationSupprimerOffre" class="ui-content">
  3. <h3>Confirmation</h3>
  4. <p>Are you sure ?</p>
  5. <a href="#" data-role="button" >Delete</a>
  6. <a href="#" data-role="button" onclick="closeSupprimerDialog()">Cancel</a>
  7. </div>

please help, Thanks