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
- function closeSupprimerDialog(id){
- alert(id); // i got id here
- $(document).delegate('#confirmationSupprimerOffre', 'click', function() {
- $(this).simpledialog({
- 'mode' : 'bool',
- 'prompt' : 'Confirmation',
- 'useModal' : true,
- 'buttons' : {
- 'Delete': {
- click: function () {
- $('#confirmationSupprimerOffre').text('delete');
- }
- },
- 'Cancel': {
- click: function () {
- $('#confirmationSupprimerOffre').text('cancel');
- },
- icon: "delete",
- theme: "c"
- }
- }
- })
- }
- }
gestion.htm
-
- <div data-role="popup" id="confirmationSupprimerOffre" class="ui-content">
- <h3>Confirmation</h3>
- <p>Are you sure ?</p>
- <a href="#" data-role="button" >Delete</a>
- <a href="#" data-role="button" onclick="closeSupprimerDialog()">Cancel</a>
- </div>