div全屏居中
<style>
#warp {
position: absolute;
width:800px;
height:400px;
left:50%;
top:50%;
margin-left:-400px;
margin-top:-200px;
border: solid 3px red;
}
</style>
<body>
<div id=warp>Test</div>
</body>
#warp {
position: absolute;
width:800px;
height:400px;
left:50%;
top:50%;
margin-left:-400px;
margin-top:-200px;
border: solid 3px red;
}
</style>
<body>
<div id=warp>Test</div>
</body>