2

I know this sounds like a super redundant question, but its not. Whenever I search for this I only get results telling me to use overflow:scroll -which I am.

I've tried this in chrome, chrome canary, safari, and firefox. I have a div with fixed height and width, some pages require scrolling others do not so I am using overflow: scroll; but the scroll bars only show when you actually scroll down while hovering over the content. I want it to be painfully obvious to my visitors that there is more content. Is there a way to have the scrollbars literally always show (whether or not the user is hovering or scrolling at that moment).

A JS solution would be cool, this question has a neat trick to tell if the scrollbar is needed, but is there a JS function that always shows it? Is there a CSS function, pretty much anything would be cool.

Thanks in advance.

EDIT: After playing around with JS I found that if you use

content.scrollTop = 0;

some browsers will flash the scrollbar, and for the other browsers use:

content.scrollTop = 1;
content.scrollTop = 0;
Community
  • 1
  • 1
B Rad C
  • 510
  • 2
  • 6
  • 18

1 Answers1

-2

You can try this:

Instead of

overflow:scroll;

try

overflow-x:hidden;
overflow-y:scroll;
Leo
  • 5,017
  • 6
  • 32
  • 55