How i can show a close button after certain elapsed, i tried settimeout but it wont work. can someone provide a basic sample to show the close button after certain time.
thanks
EDIT:
This is how i did custom buttons because someone asked me about this
var myButtons = {
'Close': function () {
},
'Do not show this again': function () {
$.ajax({
type: "POST",
url: pagename,
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (response) {
if (response.d == true) {
}
}
});
}
};
$("#div").html("").dialog({ modal: true, resizable: false, width: 830, height: 580, show: 'slow', title: '', open: function (event, ui) { $(".ui-dialog-titlebar", $("#div").parent()).hide(); }, buttons: myButtons });
thats how i did the custom buttons. the reason i had the mybuttons variable is because i use conditional statement and based on that i show different buttons when the dialog opens.
Try something like below,
DEMO
Assumption: Above code is assuming that you want to hide/show the jQuery default Close button that you see it in the dialog’s title.