单个未知大小图片在div里面垂直居中的方法。。。添加辅助元素挤一下位置达到居中
<div class="ServicesLiTopPic">
<i></i>
<img class="YuYue1" src="data:images/ReserveServices/YuYue1.png" /> </div>
.ServicesLiTopPic i {
display:inline-block;
height:100%;
vertical-align:middle
} .ServicesLiTopPic .YuYue1{display:inline-block;vertical-align:middle;}