-
移动浏览器
查看全部 -
IE最新渲染模式
查看全部 -
juery必须在bootsrap之前引用,因为js都是基于juery的
查看全部 -
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>练习</title>
<link href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">
<style>
body {
padding-top: 50px;
}
.sildebar {
background-color: #ddd;
padding-top: 20px;
}
@media (min-width:992px) {
.sildebar {
position: fixed;
top: 50px;
left: 0;
bottom: 0;
}
}
.mblff {
margin-bottom: 20px;
}
</style>
</head>
<body>
<nav class="navbar navbar-default navbar-inverse navbar-fixed-top">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button>
<a class="navbar-brand" href="#">某管理系统</a> </div>
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
<ul class="nav navbar-nav">
<li class="active"><a href="#">首页 <span class="sr-only">(current)</span></a></li>
<li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">功能 <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">功能下拉菜单</a></li>
<li><a href="#">功能下拉菜单</a></li>
<li><a href="#">功能下拉菜单</a></li>
<li role="separator" class="divider"></li>
<li><a href="#">功能下拉菜单</a></li>
<li role="separator" class="divider"></li>
<li><a href="#">功能下拉菜单</a></li>
</ul>
</li>
<li><a href="#">帮助</a></li>
</ul>
<form class="navbar-form navbar-right" role="search">
<div class="form-group">
<input type="text" class="form-control" placeholder="用户名...">
<input type="text" class="form-control" placeholder="密码...">
</div>
<button type="submit" class="btn btn-default">登录</button>
</form>
</div>
</div>
</nav>
<!--Main Content-->
<div class="container-fluid">
<div class="row">
<div class="col-md-2 sildebar">
<ul class="nav nav-pills nav-stacked">
<li role="presentation" class="active"><a href="#">首页</a></li>
<li role="presentation"><a href="#">信息建立</a></li>
<li role="presentation"><a href="#">信息查询</a></li>
<li role="presentation"><a href="#">信息管理</a></li>
<li role="presentation"><a href="#">设置</a></li>
<li role="presentation"><a href="#">帮助</a></li>
</ul>
</div>
<!--right-->
<div class="col-md-10 col-md-offset-2">
<h1>管理控制台</h1>
<hr class="divider">
<div class="mblff">
<!-- Standard button -->
<button type="button" class="btn btn-lg btn-default">Default</button>
<!-- Provides extra visual weight and identifies the primary action in a set of buttons -->
<button type="button" class="btn btn-lg btn-primary">Primary</button>
<!-- Indicates a successful or positive action -->
<button type="button" class="btn btn-lg btn-success">Success</button>
<!-- Contextual button for informational alert messages -->
<button type="button" class="btn btn-lg btn-info">Info</button>
<!-- Indicates caution should be taken with this action -->
<button type="button" class="btn btn-lg btn-warning">Warning</button>
<!-- Indicates a dangerous or potentially negative action -->
<button type="button" class="btn btn-lg btn-danger">Danger</button>
</div>
<div class="row">
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading">最新提醒</div>
<div class="panel-body">
<div class="alert alert-success" role="alert">提示您的订单(2014001)已经审批通过!</div>
<div class="alert alert-info" role="alert">提示您的订单(2014002)被打回!</div>
<div class="alert alert-warning" role="alert">提示您的订单(2013001)客户付款延迟!</div>
</div>
</div>
</div>
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading">最新提醒</div>
<div class="panel-body">
<ul class="nav nav-pills nav-stacked">
<li role="presentation"><a class="alert alert-info alert-info-lg" href="#">首页<span class="badge pull-right">42</span></a></li>
<li role="presentation"><a class="alert alert-info" href="#">信息建立<span class="badge pull-right">42</span></a></li>
<li role="presentation"><a class="alert alert-info" href="#">信息查询<span class="badge pull-right">42</span></a></li>
</ul>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading">最新提醒</div>
<div class="panel-body">
<table class="table table-striped">
<thead>
<tr>
<th>#</th>
<th>产品</th>
<th>数量</th>
<th>总金额</th>
<th>业务员</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Apple Macbook air</td>
<td>10</td>
<td>80000</td>
<td>王小贱</td>
</tr>
<tr>
<td>1</td>
<td>Apple Macbook air</td>
<td>10</td>
<td>80000</td>
<td>王小贱</td>
</tr>
<tr>
<td>1</td>
<td>Apple Macbook air</td>
<td>10</td>
<td>80000</td>
<td>王小贱</td>
</tr>
<tr>
<td>1</td>
<td>Apple Macbook air</td>
<td>10</td>
<td>80000</td>
<td>王小贱</td>
</tr>
</tbody>
</table>
<button type="submit" class="btn btn-primary">查看详细 >></button>
</div>
</div>
</div>
<div class="col-md-6">
<div class="panel panel-primary">
<div class="panel-heading">最新提醒</div>
<div class="panel-body">
<h3><span class="label label-default">NeNewNeww</span></h3>
<div class="progress">纯色
<div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="20" aria-valuemin="0" aria-valuemax="100" >70%</div>
</div>
<h3><span class="label label-default">NeNewNeww</span></h3>
<div class="progress progress-striped active"> 条纹动态色
<div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="30" aria-valuemin="0" aria-valuemax="100" >90%</div>
</div>
<h3><span class="label label-default">NeNewNeww</span></h3>
<div class="progress">叠色
<div class="progress-bar progress-bar-success" >20%</div>
<div class="progress-bar progress-bar-info progress-bar-striped" >20%</div>
<div class="progress-bar progress-bar-warning" >30%</div>
<div class="progress-bar progress-bar-danger progress-bar-striped" >15%</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script src="https://cdn.bootcss.com/jquery/1.12.4/jquery.min.js"></script>
<script type="text/javascript" src="http://cdn.bootcss.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
</body>
</html>
查看全部 -
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Hello World</title>
<link href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" rel="stylesheet">
<script src=" http://libs.baidu.com/jquery/1.9.0/jquery.js"></script>
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
<style type="text/css">
body{
padding: 5px;
}
#pal .row p{ border: 1px solid #ccc; padding: 5px;}
}
</style>
</head>
<body>
<div class="container" id="pal">
<div class="row">
<div class="col-md-4">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
<div class="col-md-4">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
<div class="col-md-4">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
</div>
<div class="row">
<div class="col-md-4">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
<div class="col-md-4 col-md-offset-4">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
</div>
<div class="row">
<div class="col-md-3 col-md-offset-3">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
<div class="col-md-3 col-md-offset-3">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
</div>
<div class="row">
<div class="col-md-6 col-md-offset-3">
<p>慕课网是一家从事互联网免费教学的网络教育公司。秉承"开拓、创新、公平、分享"的精神,将互联网特性全面的应用在教育领域,致力于为教育机构及求学者打造一站式互动在线教育品牌。</p>
</div>
</div>
</body>
</html>
查看全部 -
图片滚动
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Hello World</title>
<link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="http://cdn.bootcss.com/jquery/1.11.1/jquery.min.js"></script>
<script src="https://cdn.bootcss.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
.carousel{
height:60%;
max-height: 600px;
background-color: #000;
overflow: hidden;
}
.carousel .item{
background-color: #000;
max-height: 600px;
}
.carousel img{
width: 100%;
min-height:300px;
}
.carousel-caption p{
margin-bottom: 20px;
font-size: 16px;
}
.carousel-caption a{
margin-bottom: 30px;
}
@media (max-width: 768px){
.carousel{ min-width: 370px;}
}
</style>
</head>
<body>
<!--banner -->
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
<!-- Indicators -->
<ol class="carousel-indicators">
<li data-target="#carousel-example-generic" data-slide-to="0" class="active"></li>
<li data-target="#carousel-example-generic" data-slide-to="1"></li>
<li data-target="#carousel-example-generic" data-slide-to="2"></li>
</ol>
<!-- Wrapper for slides -->
<div class="carousel-inner" role="listbox">
<div class="item active">
<img src="http://img1.sycdn.imooc.com//5412ad400001e52014280484.jpg" alt="1 slide">
<div class="carousel-caption">
<h1>Chome</h1>
<p>Google chrome,又称Google浏览器,是一个由谷歌公司开发的网页浏览器。</p>
<a class="btn btn-lg btn-primary" href="">点我下载</a>
</div>
</div>
<div class="item">
<img src="http://img1.sycdn.imooc.com//5412ad7c0001d2eb10880541.jpg" alt="2 slide">
<div class="carousel-caption">
<h1>Chome</h1>
<p>Google chrome,又称Google浏览器,是一个由谷歌公司开发的网页浏览器。</p>
<a class="btn btn-lg btn-primary" href="">点我下载</a>
</div>
</div>
<div class="item">
<img src="http://img1.sycdn.imooc.com//5412ae5c0001653b12800644.jpg" alt="3 slide">
<div class="carousel-caption">
<h1>Firefox</h1>
<p>Google chrome,又称Google浏览器,是一个由谷歌公司开发的网页浏览器。</p>
<a class="btn btn-lg btn-primary" href="">点我下载</a>
</div>
</div>
</div>
<!-- Controls -->
<a class="left carousel-control" href="#carousel-example-generic" role="button" data-slide="prev">
<span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
<span class="sr-only">上一页</span>
</a>
<a class="right carousel-control" href="#carousel-example-generic" role="button" data-slide="next">
<span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
<span class="sr-only">下一页</span>
</a>
</div>
<!--banner end -->
查看全部 -
在IE运行最新的渲染模式
查看全部 -
4
查看全部 -
3
查看全部 -
2
查看全部 -
导航条
查看全部 -
1
查看全部 -
0.第一块ol部分是对应底部多个小点点的代码,第二块item部分是对应轮播图片的代码,第三块部分是对应左右滑动图标的代码。 1.<ol>部分,多个轮播图则引用多个data,data-slide-to=“0,1,2,3,4,5…n”,与引用<dic class=“item”>个数相对应、相同。 2.轮播图片框太大,要加一些样式限制它。限制.carousel的高度和背景。.carousel:{height:500px;backgroung-color:#000;}.carousel .item{heighe:500px;background-color:#000;} 当分辨率特别高时,有些图片填满,有些图片没填满,此时给图片也设置一个样式。.carousel.item{width:100%;使图片自动缩放去填满。} 3.要让导航栏紧挨着滚动条,此时把body的padding-top设置成与滚动框一样即可。就会紧贴着。 4.轮播图上的字体大小和间距,.carousel-caption p{margin-bottom:20px;font-size:20px;line-height:1.8;}查看全部
-
container-fluid
查看全部 -
导航
navbar-fixed-top固定顶部
navbar-inverse黑色
container默认居中
container-flus
查看全部
举报