您的位置:首页 > Web前端 > BootStrap

bootstrap栅格式布局

2017-11-20 16:18 246 查看

根据屏幕大小切换布局

<!DOCTYPE html>
<html>

<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>
屏幕自适应--栅格布局
</title>
<link rel="stylesheet" href="./css/bootstrap.min.css">
<style>

body {
background-color: rgb(170, 164, 164);
}

@media screen and (max-width: 1200px) {
body {
background-color: red;
}
}

@media screen and (max-width: 992px) {
body {
background-color: yellow;
}
}

@media screen and (max-width: 768px) {
body {
background-color: green;
}
}

@media screen and (max-width: 320px) {
body {
background-color: blue;
}
}
</style>
</head>

<body>
<script src="./js/jquery-3.2.1.min.js"></script>
<script src="./js/bootstrap.min.js"></script>
</body>

</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  bootstrap 栅格布局