开发者

Jquery automatic modal popup

HI,

Does anyone know the example of jQuery pop up modal window where you can open automatically on page load and close it after 10 sec for example. Which support开发者_JAVA技巧s iframe integration. Thank you


The jQuery UI modal dialog will automatically open on page load if you declare no other parameters in its initialisation call:

$(function() {
    $( "#dialog" ).dialog();
});

To have the dialog close after a delay you should be able to include a call further down your DOM ready event:

setTimeout($('#dialog').dialog('close'), 10000);


not sure what are you trying to show in your pop up modal window, but you can try using fancybox which have a close function even from the iframe.

thus you can just set a timer function to run for ten seconds after the user clicks on it and close the window.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜