Html
    Css
    Js

    
                        
.vmspan {
	height:100%;
	display:inline-block;
	vertical-align:middle;
}
.tabmspan {
	display:table-cell;
	vertical-align:middle;
}
.vm {
	vertical-align:middle;
}
ul li {
	float:left;
	margin-right:13px;
}
ul li div {
	display:table-cell;
	width:144px;
	height:144px;
	border:1px solid red;
	font-size:18px;
	text-align:center;
	vertical-align:middle;
}
ul li div img {
	vertical-align:middle;
}
div a {
	display:table-cell;
	width:100px;
	padding:20px;
	text-align:center;
	vertical-align:middle;
	border:1px solid red
}
div a img {
	vertical-align:middle;
}
.box {
	background:black;
	font-size:30px;
	color:white;
	padding-left:20px;
	line-height:5px;
}
.dot {
	display:inline-block;
	width:4px;
	height:4px;
	background:white;
	vertical-align:text-bottom;
}

                        
↑上面代码改变,会自动显示代码结果 jQuery调用版本:2.1.4
 立即下载

css js垂直居中

1
      羊肉串儿TA爸0
      2017/7/5 15:54:55