[英]Sub menus fallback to jqGrid
我在其中一个页面中使用Asp.Net
jqGRid
,没有问题。但是,在此阶段,我有一个仅包含几个子菜单的下拉菜单,我遇到的问题是我的子菜单出现在jqGRid
后面。我不知道如何解决这个问题。我试图给包装菜单的div赋予更高的z-index
,但是没有帮助。
任何建议,不胜感激。
谢谢
因此,通过将以下样式设置为包含jqGrid的div jgGridDiv来解决了此问题。
#jqGridDiv
{
position:relative;
z-index:1;
}
现在它工作正常,而且我为包含菜单的div设置了更高的z-index,这非常重要。
我建议您使用Chrome的开发人员工具检查创建jqGrid的div的“计算样式”。
我知道两个问题可能会影响您所描述的结果:
<head>
放置行<meta http-equiv="X-UA-Compatible" content="IE=edge" />
。 它可以与所有!DOCTYPE
一起使用,但HTML5 !DOCTYPE
( <!DOCTYPE html">
除外。更安全的做法是设置"X-UA-Compatible"
<system.webServer>
<httpProtocol>
<customHeaders>
<clear />
<add name="X-UA-Compatible" value="IE=edge"/>
</customHeaders>
</httpProtocol>
</system.webServer>
(如此处 ,但具有"X-UA-Compatible"
HTTP标头的另一个值)
z-index
将从您放置jqGrid的某个父div继承。 在这种情况下,您可以考虑将<table>
和传呼器<div>
放置在其他“容器” div中,并按照div position: relative; z-index: auto;
的样式进行position: relative; z-index: auto;
position: relative; z-index: auto;
或position: relative; z-index: 1;
position: relative; z-index: 1;
(或其他小值)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.