Auto Close Dialog Box Jquery
Jquery Dialog Box Auto Close
HTML<a href="http://lesson8.blogspot.in/2012/05/auto-close-dialog-box-jquery.html" id="show">Click to Open and auto close Dialog Box</a> <b>Please wait for 5 Seconds and JQuery UI Dialog box will auto close.</b> <div id="dialog" title="Dialog Title"> This is My Dialog box Description/Content This is Auto Close Dialog Box.</div>JavaScript
$(document).ready(function () { $("#dialog").dialog({ autoOpen: false }); $("#show").click( function () { $("#dialog").dialog('open'); //Change content on the fly ChangeMessage("JQueryUI Auto Dialog Close Box Example"); //Auto Close JQueryUI Dialog Box AutoCloseDialogBox(5000); return false; } ); function ChangeMessage(Message) { $("#dialog").html(Message); } function AutoCloseDialogBox(WaitSeconds) { //Auto Close Dialog Box after few seconds setTimeout( function () { $("#dialog").dialog("close"); }, WaitSeconds); } });Demo / Download
Model Dialog Asp.Net With Jquery
Auto Close Dialog Box Jquery
Reviewed by Bhaumik Patel
on
1:56 AM
Rating: