Alex Rivera | Logout

Is there a way to style HTML5's range control?

Asked 2010-06-05T05:33:42.297
32

Is there a way to style HTML5's range control? Is it possible to change the color of the line the slider slides on?

Edit
Report

1 Answer

38

Turns out, there is in webkit:

 input[type="range"]{
   -webkit-appearance:none !important;
 }

 input[type="range"]::-webkit-slider-thumb{
   -webkit-appearance:none !important;  
 }

You can then add whatever attributes you need to each those selectors. Background, gradient, etc...

Hope that helps!

answered 2010-06-10T20:04:09.083

Your Answer