title: twitter bootstrap change background color of button with dropdown menu on click
body: <p>In Twitter Bootstrap 2, <strong>I want to be able to change the background color of a button in the navbar but only when the dropdown menu is clicked</strong>. I tried changing the CSS and I understood that the class background-color you can change is</p>
  
  <pre><code>    .dropdown-toggle {
       *margin-bottom: -3px;
       background-color: #fffffff;
       }
  </code></pre>
  
  <p>but that didn't work as it does it statically. I also tried</p>
  
  <pre><code>     .dropdown-toggle:active,
      .open .dropdown-toggle {
      outline: 0;
      background-color: #fffffff;
       } 
  </code></pre>
  
  <p>but that didn't work either (nothing happens).</p>
  
  <p>HTML looks like this:</p>
  
  <pre><code>  &lt;div class="navbar navbar-inverse navbar-fixed-top"&gt;
    &lt;div class="navbar-inner"&gt;
      &lt;div class="container"&gt;
        &lt;button type="button" class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse"&gt;
          &lt;span class="icon-bar"&gt;&lt;/span&gt;
          &lt;span class="icon-bar"&gt;&lt;/span&gt;
          &lt;span class="icon-bar"&gt;&lt;/span&gt;
        &lt;/button&gt;
        &lt;a class="brand" href="#"&gt;...&lt;/a&gt;
        &lt;!-- nav-collapse indicates what will be in collapsed navigation --&gt;
        &lt;div class="nav-collapse collapse"&gt;
          &lt;ul class="nav"&gt;
            &lt;li class="active"&gt;&lt;a href="#"&gt;&lt;i class="icon-home icon-white"&gt;&lt;/i&gt; Home&lt;/a&gt;&lt;/li&gt;
            &lt;li&gt;&lt;a href="#about"&gt;...&lt;/a&gt;&lt;/li&gt;
            &lt;li class="dropdown"&gt;
          &lt;a href="#" class="dropdown-toggle" data-toggle="dropdown"&gt;...&lt;b class="caret"&gt;&lt;/b&gt;&lt;/a&gt;
      &lt;ul class="dropdown-menu"&gt;
            &lt;li&gt;&lt;a href="#"&gt;...&lt;/a&gt;&lt;/li&gt;
            &lt;li&gt;&lt;a href="#"&gt;...&lt;/a&gt;&lt;/li&gt;
                &lt;/ul&gt;
            &lt;/li&gt;
            ...
  </code></pre>
  
  <p>So I figured it was a JavaScript problem, but I'm not really sure how to do it. Does anyone else know and can help?</p>
  
  <p><a href="http://jsfiddle.net/3xdws/" rel="nofollow">http://jsfiddle.net/3xdws/</a> code is here but it doesn't seem to show the dropdown items for some reason? oh well</p>