首页 > 其他 > 详细

Bootstrap 环境设置

时间:2015-07-24 17:25:51      阅读:263      评论:0      收藏:0      [点我收藏+]

下载文件: 官网--getbootstrap.com---Download---bootstrapDownload

如果不想下载文件 可以直接引用官方的链接:

技术分享
1 <!-- Latest compiled and minified CSS -->
2 <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
3 
4 <!-- Optional theme -->
5 <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">
6 
7 <!-- Latest compiled and minified JavaScript -->
8 <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
View Code


bootstrap文件内容

bootstrap/
├── css/
│   ├── bootstrap.css
│   ├── bootstrap.css.map
│   ├── bootstrap.min.css
│   ├── bootstrap-theme.css
│   ├── bootstrap-theme.css.map
│   └── bootstrap-theme.min.css
├── js/
│   ├── bootstrap.js
│   └── bootstrap.min.js
└── fonts/
    ├── glyphicons-halflings-regular.eot
    ├── glyphicons-halflings-regular.svg
    ├── glyphicons-halflings-regular.ttf
    ├── glyphicons-halflings-regular.woff
    └── glyphicons-halflings-regular.woff2

 导入jQuery  和bootstrap的CSS JS,因为bootstrap所有的JS插件都依赖于jQuery,因此jQuery要在Bootstrap之前引用。

官方给出了HTML的模板

技术分享
 1 <!DOCTYPE html>//定义HTMl5
 2 <html lang="en">
 3   <head>
 4     <meta charset="utf-8">//utf-8编码
 5     <meta http-equiv="X-UA-Compatible" content="IE=edge">//IE渲染模式
 6     <meta name="viewport" content="width=device-width, initial-scale=1">
 7     <!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
 8     <title>Bootstrap 101 Template</title>
 9 
10     <!-- Bootstrap -->
11     <link href="css/bootstrap.min.css" rel="stylesheet">
12 
13     <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
14     <!-- WARNING: Respond.js doesn‘t work if you view the page via file:// -->
15     <!--[if lt IE 9]>
16       <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
17       <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
18     <![endif]-->
19   </head>
20   <body>
21     <h1>Hello, world!</h1>
22 
23     <!-- jQuery (necessary for Bootstrap‘s JavaScript plugins) -->
24     <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
25     <!-- Include all compiled plugins (below), or include individual files as needed -->
26     <script src="js/bootstrap.min.js"></script>
27   </body>
28 </html>
View Code

 


 

Bootstrap 环境设置

原文:http://www.cnblogs.com/wss2881938/p/4673686.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!