In CSS, simply add the below definitions to the top of your page to customize the browser’s scrollbar colors. The great thing about CSS is that browsers that don’t understand it will just skip it. Scrollbar painting is supported by IE5.5 and up.
Bet you never realized the scrollbar consisted of that many components! The first three definitions are the most important, as they correspond to the most visible aspects of the scrollbar. Feel free to play around with the other definitions to see what they affect.
Here’s an example of a “blinking” scrollbar, which changes color every second:
mode=(mode==0)? 1 : 0
I’m seeing more and more sites customize the scrollbar color to blend in with the rest of their sites. I hope you find these tips useful in helping you do the same!
Mike is an aspiring Web designer. He's currently studying full time in the Unversity of British Columbia, Canada.