我刚刚将 jQuery UI 对话框放入网页中。这是我第一次使用它。我以为我已经正确设置了 bgiframe 属性,但是当我在 IE6 中检查它时,它仍然落后于下拉列表。这是我的 JavaScript 代码。页面上没有任何闪光。一个简单的 div,其中包含文本和围绕“jClick”的一些文本的锚点。任何想法为什么会在 IE6 中发生这种情况?
$(document).ready(function(){
$("#dialog").dialog({
bgiframe: true, autoOpen: false,
overlay: { backgroundColor: '#000', opacity: 0 },
width: 400,
height: 200,
modal: true,
buttons: {
'Delete all items in recycle bin': function() {
$(this).dialog('close');},
Cancel: function() {$(this).dialog('close');}
}
});
$("#jClick").click(function(event){
$("#dialog").dialog('open');
event.preventDefault();
});
});