如何修改bootstrap供我们使用。 [英] How to modify bootstrap for our use.

查看:69
本文介绍了如何修改bootstrap供我们使用。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的网站上使用bootstrap。我想改变页眉类的背景颜色。我在css文件中有变化。但改变并没有反映在网站上。



请帮助我这样做。



我尝试过:



.page-header

{

1 background-color :蓝色;

2背景颜色:蓝色!重要;

}

这两行我试过但没有反映出来的变化

i am using bootstrap in my website. i want to change background color of page-header class. i have change in css file . but change is not reflected in site.

kindly assist me to do so.

What I have tried:

.page-header
{
1 background-color:blue;
2 background-color:blue !important;
}
both line i have tried but no changes was reflected

推荐答案

将它放在bootstrap css库之后,例如

Put it after the bootstrap css library, e.g.
<!DOCTYPE html>
<html lang="en">
<head>
  <title>Bootstrap Example</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script>
  <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
<style>
.page-header
{
  background-color:blue;
}
</style>
</head>
<body>

<div class="container">
  <div class="page-header">
    <h1>Example Page Header</h1>      
  </div>
  <p>This is some text.</p>      
  <p>This is another text.</p>      
</div>

</body>
</html>


这篇关于如何修改bootstrap供我们使用。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆