CSS垂直居中完美實用例項
<!DOCTYPE HTML>
<html>
<head>
<meta meta charset="utf-8">
<title>CSS垂直居中</title>
<style type="text/css" media="all">
body{color:black;background-color:white;padding:50px;font-size: 12px;line-height:16px;font-family:arial; color: #1E346E;}
* {margin: 0;padding:0;border-width: 0;}
.list{vertical-align: middle;width:640px;margin-bottom: 1px;border: solid 1px #00a0da;background-color:#F0F5FF; }
.list:hover{background-color:#d9e7f5;}
/*----------set vertical align middle----------*/
.list p,.list b { vertical-align: middle;display: -moz-inline-stack;display:inline-block;zoom:1;*display:inline;}
.list p { padding:10px;}
/*----------set min-height----------*/
.list b { height:52px;width:1px;overflow:hidden;margin-left:-1px;background-color:#009Cd0;}
</style>
</head>
<body>
<div class="list"><b> </b><p style="width:80px;">first class</p><p style="width:160px;">Can be modified</p><p style="width:160px;">Can be refunded.</p><p
style="width:160px;">Can be endorsed</p></div>
<div class="list"><b> </b><p style="width: 80px;">Economy class</p><p style="width:160px;">Can be modified</p><p style="width:160px;">Can be refunded.</p><p
style="width:160px;">Can be endorsed</p></div>
<div class="list"><b> </b><p style="width:80px;">23% off Economy class</p><p style="width:160px;">One free change permitted within same class if available; further
changes charged 10% of fare. Passengers must go to CA ticketing office to process fee-based changes.</p><p style="width:160px;">10% of fare charged. </p><p
style="width:160px;">Can not be endorsed</p></div>
<div class="list"><b> </b><p style="width:80px;">-6% off Economy class</p><p style="width:160px;">Free change permitted within same class if available at least 4 days
prior to departure.</p><p style="width:160px;">20% of fare charged (minimum CNY50 charge).</p><p style="width:160px;">Can not be endorsed</p></div>
<div><A href="http://www.999jiujiu.com/">http://www.999jiujiu.com/</A></div>
</body>
</html>
<html>
<head>
<meta meta charset="utf-8">
<title>CSS垂直居中</title>
<style type="text/css" media="all">
body{color:black;background-color:white;padding:50px;font-size: 12px;line-height:16px;font-family:arial; color: #1E346E;}
* {margin: 0;padding:0;border-width: 0;}
.list{vertical-align: middle;width:640px;margin-bottom: 1px;border: solid 1px #00a0da;background-color:#F0F5FF; }
.list:hover{background-color:#d9e7f5;}
/*----------set vertical align middle----------*/
.list p,.list b { vertical-align: middle;display: -moz-inline-stack;display:inline-block;zoom:1;*display:inline;}
.list p { padding:10px;}
/*----------set min-height----------*/
.list b { height:52px;width:1px;overflow:hidden;margin-left:-1px;background-color:#009Cd0;}
</style>
</head>
<body>
<div class="list"><b> </b><p style="width:80px;">first class</p><p style="width:160px;">Can be modified</p><p style="width:160px;">Can be refunded.</p><p
style="width:160px;">Can be endorsed</p></div>
<div class="list"><b> </b><p style="width: 80px;">Economy class</p><p style="width:160px;">Can be modified</p><p style="width:160px;">Can be refunded.</p><p
style="width:160px;">Can be endorsed</p></div>
<div class="list"><b> </b><p style="width:80px;">23% off Economy class</p><p style="width:160px;">One free change permitted within same class if available; further
changes charged 10% of fare. Passengers must go to CA ticketing office to process fee-based changes.</p><p style="width:160px;">10% of fare charged. </p><p
style="width:160px;">Can not be endorsed</p></div>
<div class="list"><b> </b><p style="width:80px;">-6% off Economy class</p><p style="width:160px;">Free change permitted within same class if available at least 4 days
prior to departure.</p><p style="width:160px;">20% of fare charged (minimum CNY50 charge).</p><p style="width:160px;">Can not be endorsed</p></div>
<div><A href="http://www.999jiujiu.com/">http://www.999jiujiu.com/</A></div>
</body>
</html>
相關文章
- css水平垂直居中程式碼例項CSS
- css實現的div垂直居中效果程式碼例項CSS
- CSS多行文字垂直居中例項程式碼CSS
- css實現div全屏水平垂直居中效果程式碼例項CSS
- css實現的div垂直水平居中程式碼例項CSS
- css多行文字垂直居中程式碼例項CSS
- css實現的多行文字垂直居中效果程式碼例項CSS
- css實現的多行文字垂直居中程式碼例項CSS
- css3實現元素垂直水平居中程式碼例項CSSS3
- 純CSS完美實現垂直水平居中的6種方式CSS
- css文字在元素中垂直居中程式碼例項CSS
- css3實現div元素垂直水平居中程式碼例項CSSS3
- CSS 垂直居中CSS
- div垂直水平居中例項程式碼
- div垂直居中-CSS元素垂直居中方法CSS
- CSS垂直居中和水平居中CSS
- CSS水平居中和垂直居中CSS
- jQuery實現的div垂直水平居中例項程式碼jQuery
- css 水平垂直居中實現方式CSS
- 5種實現垂直居中cssCSS
- css水平垂直居中CSS
- CSS垂直水平居中CSS
- css實現固定高度及未知高度文字垂直居中的完美解決方案CSS
- CSS實現垂直居中的問題CSS
- css實現的div垂直居中效果CSS
- css3實現垂直居中-flexCSSS3Flex
- CSS實現垂直居中的常用方法CSS
- CSS未知高度垂直居中CSS
- CSS垂直居中方法CSS
- CSS水平居中和垂直居中的方法CSS
- css設定元素在瀏覽器中垂直水平居中程式碼例項CSS瀏覽器
- css垂直居中怎麼設定?文字上下居中和圖片垂直居中CSS
- Css實現垂直居中的幾種方法CSS
- css3實現元素垂直居中效果CSSS3
- CSS垂直居中的12種實現方式CSS
- CSS 實現垂直居中的 5 種方法CSS
- 關於css 的垂直居中CSS
- css水平、垂直居中的方法CSS