学习使用bootstrap3栅格系统_javascript技巧

WBOY
Release: 2016-05-16 15:06:00
Original
1596 people have browsed it

一、bootstrap开发环境搭建
1. 下载bootstrap,http://www.bootcss.com/
2. 下载jquery, 通过IE直接访问http://code.jquery.com/jquery-2.0.3.min.js
3. 在html页面中导入bootstrap与jquery的js,css文件,.viewport的 标签,这个标签可以修改在大部分的移动设备上面的显示,加如 if lt IE 9...等是为了在ie9以下的兼容。
模板如下

     Insert title here     
  
Copy after login

二. 栅格系统
1. boostrap把桌面分隔成 由12行 * n 列的表格进行布局, 这是boostrap进行而已的核心。
2. .row 进行行级划分,必须包含在 .container下。
3. col-xx-*进行列级划分,如下图

1
2
3
4
5
6
7
8
Copy after login

4.列偏移,通过 col-xx-offset-*来实现

1
2
3
4
5
6
7
Copy after login

5. 列排序,能过.col-xx-push-* 和 .col-xx-pull-* 实现列的向左或向右排序

1
2
3
5
6
7
Copy after login

6. 列嵌套,row嵌套在col中即可。

1
2
3
5
6
7
Copy after login

以上就是本文的全部内容,希望对大家的学习有所帮助。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!