Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Scrollbar not working

Below is my html file,

<div class="col-xs-6 col-sm-3 my1" id="qwer1" role="navigation">        <!--Change is made here-->
          <div class="menuBar">
            <ul class="menuList" id="menuList">
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <li><a href="#">Update 1</a></li>
              <hr>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
              <li><a href="#">Chat 1</a></li>
            </ul>
          </div><!--/.well -->
        </div><!--/span-->

Below is the css file,

.my1
{
    position:fixed;
    left:78%;
    border-left:1px solid black;
    border-bottom:1px solid black;
    width:20%;
    top:14%;
    height:auto;
    overflow:scroll;
    scroll-face-color:red;
}

The content of the html file is well out of the sreen, but eventhough the scrollbar is not operable. Moreover, I have specified the color of the scrollbar as red but the color effect also doesnt seem to be working. Below is the screenshot of browser,

enter image description here

How can I activte this scrollbar? Thanks in advance.

like image 952
Saumil Avatar asked Sep 17 '25 18:09

Saumil


2 Answers

The problem is that you specified:

height:auto;

under the .my1 rule, so the div will expand in height as much as needed to accommodate the content.

If you had fixed the height, you would activate the scroll bar.

See demo at: http://jsfiddle.net/audetwebdesign/myPZB/

As far as trying to style the color of the scroll bar, the property of interest is:

scrollbar-face-color

and I think this is only supported on IE browsers at this time.

Reference: http://msdn.microsoft.com/en-us/library/ie/ms531157%28v=vs.85%29.aspx

like image 127
Marc Audet Avatar answered Sep 19 '25 08:09

Marc Audet


height:50%

try this..I tested ok..if 'auto' , scroll is not work

like image 30
lynndragon Avatar answered Sep 19 '25 07:09

lynndragon