带有doctype和z-index的IE10 html5
我有这个样本: 它是一个内部包含2个div的div,其中一个是一个具有特定大小(例如500x500)和高zIndex(9998)的表,另一个div内部有一个输入文本和低zIndex。 问题是:为什么在IE10中,如果zindex表覆盖了整个输入,我就能够访问它? 它可以在谷歌浏览器、火狐、Safari等浏览器上正常工作带有doctype和z-index的IE10 html5,html,z-index,internet-explorer-10,doctype,Html,Z Index,Internet Explorer 10,Doctype,我有这个样本: 它是一个内部包含2个div的div,其中一个是一个具有特定大小(例如500x500)和高zIndex(9998)的表,另一个div内部有一个输入文本和低zIndex。 问题是:为什么在IE10中,如果zindex表覆盖了整个输入,我就能够访问它? 它可以在谷歌浏览器、火狐、Safari等浏览器上正常工作 <!DOCTYPE html> <html> <head></head> <body>
<!DOCTYPE html>
<html>
<head></head>
<body>
<div style="width:100%; height:100%">
<div style="left: 0px; top: 0px; width: 663px; height: 574px; display: block; position: absolute; z-index: 99998;">
<table width="100%" height="100%">
<tbody>
<tr>
<td> </td>
</tr>
</tbody>
</table>
</div>
<div style="left: 11px; top: 27px; width: 110px; height: 36px; display: block; position: absolute; z-index: 0;">
<div style="left: 0px; top: -15px; height: 15px; display: block; position: absolute; z-index: 2;"><font class="label" style="white-space: nowrap; cursor: default;" draggable="false"><strong>Login</strong><strong style="color: rgb(255, 0, 0);"> *</strong></font>
</div>
<div style="left: 0px; top: 0px; width: 110px; height: 21px; display: block; position: absolute; z-index: 2;">
<input name="WFRInput100000005" class="edit" style="z-index:1;width: 110px; height: 21px; text-decoration: none; background-color: rgb(255, 255, 255);" type="text" maxlength="20" autocomplete="on">
</div>
</div>
</div>
</body>
登录*
还有一个老问题,我知道,但我自己也遇到了这个问题。问题在于IE倾向于忽略透明元素(有关更多详细信息,请参阅)。我可以通过在表的父div中添加白色背景色(不透明度设置为0)来修复您的小提琴
以下是最新的小提琴:
具体来说,以下是发生变化的原因:
<div style="left: 0px; top: 0px; width: 663px; height: 574px; display: block; position: absolute; z-index: 99998; background-color: white; opacity:0;">