<title>CSS等比例缩放图片</title>
<style type="text/css">
.suofang {MARGIN: auto;WIDTH: 200px;}
.suofang img{MAX-WIDTH: 100%!important;HEIGHT: auto!important;width:expression(this.width > 200 ? "200px" :     this.width)!important;}
</style>
<body>
    <div class="suofang">
        <img src="http://www.baidu.com/img/bdlogo.gif"/>
    </div>
</body>