DIV内图片居中显示

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>新建网页 1</title>
<style>
div {
border:1px solid red;
text-align:center;
}
img {
margin:0 auto
}
</style>
</head>
<body>
<div><img src="http://www.17cha8.cn/images/default/logo.gif"></div>
</body>
</html>

 

posted @ 2013-08-13 20:51  风随叶舞  阅读(282)  评论(0编辑  收藏  举报