Jquery Modal窗口有mvc 3 razor局部视图问题

时间:2012-08-22 16:48:46

标签: jquery asp.net-mvc razor jquery-ui-dialog

好的,所以我一直在为我目前正在处理的网站的一些功能使用一些jquery模式窗口。模态窗口全部打开,但它们绝对没有样式,也没有显示叠加。以下是我为模态定义div的方法:

<div class="ui-overlay"><div class="ui-widget-overlay"></div><div class="ui-widget-shadow ui-corner-all" style="width: 302px; height: 152px; position: absolute; left: 50px; top: 30px;"></div></div>
            <div  style="position: absolute; width: 280px; height: 130px;left: 50px; top: 30px; padding: 10px;" class="ui-widget ui-widget-content ui-corner-all"></div>
<div id="postEventPanel"></div> //this is the actual modal window

我正在通过jquery.load加载视图的内容:

$('#postEventPanel').load(loadUrl);

并设置如下对话框选项:

  $('#postEventPanel').dialog({
    width: 650,
    modal:true,
    autoOpen: true,
    resizable: true,

    show: { effect: 'drop', direction: "up" }

}).show();

所以我遇到的问题是叠加层没有显示,也没有任何样式。 我使用主题滚轮生成我自己的主题,我已将其包含在我的应用程序布局页面中。

以下是我看到的问题的屏幕截图:

This is a screen capture of the problem I am having, see that there is no styles, not even the default styles for the modal.

任何帮助都非常感谢大家, 感谢

1 个答案:

答案 0 :(得分:0)

检查与模态窗口样式关联的CSS是否正确加载/引用。此外,如果您使用的是Firefox并且使用的是Firebug等调试器,请检查控制台选项卡上是否存在任何javascript问题。