开发者

problems with modal window/background

I'm trying to make modal window for my website, I have a problem with overlay or modal div I'm not sure what is the problem.

The thing is everything except modal window shouldn't be clickable, but for some reason my navigation <ul><li> tags are visible and clickable. Here is css of my modal window :

element.style {
display:block;
left:50%;
margin-left:-210px; //generated with javascript
margin-top:-85px; //generated with javascript
position:fixed;
top:50%;
width:450px;
z-in开发者_C百科dex:100;
}

Here is the css of my background overlay :

element.style {
height:1436px; //generated with javascript
left:0;
opacity:.75;
position:absolute;
top:0;
width:100%;
z-index:105;
}

What am I doing wrong ? thank you


Check the z-index property of your li tags (or the underlying ul) and either set it below 100, or set the z-index of your modal window and overlay so it's higher than that of the lis.


It appears you have the values of your z-index backwards. The higher the number, the closer it is. Your background is set to 105 but the elements on top are set to 100.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜