0
What is the use of step attribute in <input> tag?
Example from a quiz question: <input type="number" name="values" min="0" max="30" step="7" value="0"> Please explain me this code and also about these combinations: 14, 0, 28, 7, 17 0, 21, 7, 28, 14 7, 23, 14, 0, 28 30, 0, 7, 28, 14 Why was second one the right answer?
3 Answers
+ 8
when you have input type number, on the input field in the right you have 2 arrows - to increase and to decrease. and the step means how big should the increase or decrease be. So for example if you set the step to 5 you increase the number by 5 -- 0,5,10,15,20...
+ 1
Thanks Proff
- 1
Profesionals use Tk library for C#,C++,python,java and step +- aren't problem