The following dialog box works nicely when clicked upon:
<a href="#" onclick="jQuery('#dialogX').dialog('open');
return false"><? echo __("Under Construction")?></a>
The javascript sitting at the bottom of the html triggers the action:
jQuery("#dialogX").dialog({bgiframe: true, autoOpen: false, modal: true});
Now, what I would wish, is to have the dialog popup after say 2 seconds (insterad of immediately). I saw the option autoOpen and when setting the value to 2000 instead of false, that helas dit not work: it opens immediately. What am I missing?
Thanks very much for your hints and wish you a nice weekend.
You can use
from https://developer.mozilla.org/en/DOM/window.setTimeout It executes a code snippet or a function after specified delay.
So
should solve your problem.
Also have a look at the
.delay( n )method. http://api.jquery.com/delay/