html - Dynamically create in PHP a drop-down list from a range of numbers *with increments* -
In PHP, I need to create a drop-down list of dynamically numerical options:
Code> & lt; Select & gt; & Lt; Option value = "120" & gt; 120 cm & lt; / Options & gt; & Lt; Option value = "121" & gt; 121 cm & lt; / Options & gt; & Lt; Option value = "122" & gt; 122 cm & lt; / Options & gt; & Lt; Option value = "123" & gt; 123 cm & lt; / Options & gt; & Lt; Option value = "etc ...
I have to specify only the start and end count.
Thanks for any help
resonance "& lt; Select & gt; "$ range = range (120,130); foreach ($ cm as limit $) {echo" and option option = '$ cm' & gt; $ Cm cm & lt; / Option & gt; "}} echo" & lt; / Select & gt; ";
function can handle all the conditions you describe in the comment.
category (30.5, 50.5, 0.5); // 30.5, 31, 31.5, 32, etc. Category (30, 50, 2); // 30, 32, 34, 36, 38, 40 etc.
Comments
Post a Comment