Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTML sliding bars?

how does one create a sliding bar using HTML? I cannot seem to find anything in the official documentation.

like image 630
Tom Avatar asked Sep 11 '10 19:09

Tom


People also ask

How do I create a vertical range slider in HTML?

For Chrome, use -webkit-appearance: slider-vertical . For IE, use writing-mode: bt-lr . For Firefox, add an orient="vertical" attribute to the html. Pity that they did it this way.

What is slider control in HTML?

The <input type="range"> defines a control for entering a number whose exact value is not important (like a slider control). Default range is 0 to 100. However, you can set restrictions on what numbers are accepted with the attributes below. max - specifies the maximum value allowed.

Is slider in HTML5 tag?

HTML5 brought a lot of new tags and new rules on how the old ones should be used. One of them is the range input element, or the slider.


2 Answers

HTML5 does, in fact, have support for sliders:

<input type="range" min="0" max="10" step="2" value="6">

...browsers are expected to render type="range" as a slider control. At time of writing, the latest versions of Safari, Chrome, and Opera all do this. (Sadly, the iPhone renders it as a simple text box. It doesn’t even optimize its on-screen keyboard for numeric input.) All other browsers simply treat the field as type="text", so there’s no reason you can’t start using it immediately. (diveintohtml5.ep.io)

like image 176
Ryan Kinal Avatar answered Oct 20 '22 10:10

Ryan Kinal


You could use the JQuery UI Slider

(Yet another JavaScript question that is answered with JQuery)

like image 3
GvS Avatar answered Oct 20 '22 12:10

GvS