我一直在使用 chrome 和 ff 开发网页。我最近被告知它也必须在 IE 中工作。我已经解决了 IE 双填充问题。问题是在 javascript setinterval 导致 div 被替换后,我的“网格”的内容消失了。只有在 IE 中查看页面时才会发生这种情况。
这是通往动态创建和打印出来的页面的代码
<div id=\"col1a\" style=\"float:left; width:605px; height:300px;\"> \
<div id=\"GridContent\" class=\"FormContent\"> \
<div id=\"ContentPlaceHolder1_FormSection\" class=\"FormSection\"> \
<div id=\"ContentPlaceHolder1_ProgramGridHeader\" class=\"ProgramGridHeader\"> \
<div id=\"ContentPlaceHolder1_HeaderRow\" class=\"HeaderRow\"> \
<div readonly=\"readonly\" class=\"Cell\" style=\"width: 57px\">Stage</div><div class=\"Cell\" style=\"width: 78px\">Type</div><div class=\"Cell\" style=\"width: 50px\">Time</div><div class=\"Cell\" style=\"width: 44px\">Int</div><div class=\"Cell\" style=\"width: 44px\">Dry</div><div class=\"Cell\" style=\"width: 44px\">Wet</div><div class=\"Cell\" style=\"width: 52px\">RH%</div><div class=\"Cell\" style=\"width: 72px\">Option</div><div class=\"Cell\" style=\"width: 72px\">Damper</div><div class=\"Cell\" style=\"width: 44px\">Fan</div> \
</div><br /> \
<div class=\"Row\" position: relative;> \
"};
以下是我仅适用于 IE 的 CSS
.Row { border: solid 0px green; float: left; min-width: 0; clear:both; position: relative; -webkit-border; padding 1;}
.RowCompleted { border: solid 0px #7F9DB9; background-color: #C0C0C0; color: #000;}
.RowNoShower { border: solid 0px #7F9DB9; background-color: #FFF; color: #000; min-width: 0; }
.RowColdShower { border: solid 1px #7F9DB9; background-color: #ADD8E6; color: #000; }
.RowWarmShower { border: solid 1px #7F9DB9; background-color: #FB0; color: #000; }
.RowHotShower { border: solid 1px #7F9DB9; background-color: #F00; color: #FFF; }
.RowInProgress { border: solid 0px #7F9DB9; background-color: #0F0; color: #000;}
.RowPaused { border: solid 0px #7F0DB9; background-color: #00F; color: #FFF;}
非常感谢帮助理解内容消失的原因-谢谢--