0

I've been fiddling with the css for a long time now, nothing's working.

I succeeded in changing the text colors, but the background color remains stubborn

source: blackdeath1098.github.io

vanburen
  • 21,502
  • 7
  • 28
  • 41
therealnemis
  • 51
  • 1
  • 8

3 Answers3

2

You have used...

.navbar-default {
    background-color: rgba(0, 0, 0, 0);
}

What you should be using instead...

.navbar-default {
    background: transparent;
}

DEMO

Mohd Abdul Mujib
  • 13,071
  • 8
  • 64
  • 88
  • I'm running prepros, and it doesn't show the change, still the same solid background. – therealnemis Dec 29 '16 at 05:28
  • Did you try setting the value, or did you try overriding the rule if thats the case then you can try by using `background: transparent!important;` just to be sure. – Mohd Abdul Mujib Dec 29 '16 at 15:06
0

You have used...

.navbar-default {
    background-color: rgba(0, 0, 0, 0);
}

What you need to be use instead...

.navbar-default {
    background-color: rgba(0, 0, 0, 1);
}
ADH - THE TECHIE GUY
  • 4,125
  • 3
  • 31
  • 54
0

.navbar-default {
    background-color: transparent !important;
    border-color: transparent !important;
}
<!DOCTYPE html>
<html lang="en">
<head>
  <title>Bootstrap Case</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
  <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</head>
<body style="background-color: #ccffff;">

<nav class="navbar navbar-default">
  <div class="container-fluid">
    <div class="navbar-header">
      <a class="navbar-brand" href="#">WebSiteName</a>
    </div>
    <ul class="nav navbar-nav">
      <li class="active"><a href="#">Home</a></li>
      <li><a href="#">Page 1</a></li>
      <li><a href="#">Page 2</a></li>
      <li><a href="#">Page 3</a></li>
    </ul>
  </div>
</nav>
  
<div class="container">
  <h3>Basic Navbar Example</h3>
  <p>A navigation bar is a navigation header that is placed at the top of the page.</p>
</div>

</body>
</html>
Vaibhav Shettar
  • 790
  • 2
  • 9
  • 20