//方法一:通用方案,可兼容IE6/7
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>无标题文档</title>
<style>
.box{ width:800px;height:600px;border:2px solid #000; text-align:center;}
span{ display:inline-block; height:100%; vertical-align:middle;}
img{ vertical-align:middle;}
</style>
</head>
<body>
<div class="box">
<img src="bigptr.jpg" />
<span></span>
</div>
</body>
</html>
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>无标题文档</title>
<style>
//方法二:IE6下有效,标准浏览器无效
.box{width: 800px;height: 600px;text-align: center;border: 2px solid black;position: relative;}
img{vertical-align: bottom;position: absolute;left: 0;top: 0;right: 0;bottom: 0;margin: auto;}
</style>
</head>
<body>
<div class="box">
<div><img src="bigptr.jpg" /></div>
</div>
</body>
</html>