This is code that I use, can someone tell me how to make that input have min and max value. I tried the html attribute max="10" but it's not working. I want to set min value to be 0 and max 10. And when you click on plus you can't add more point when field free points reach 0 points.
<input type="button" id="minus" value="-" onclick="textb.value = (textb.value-1);textc.value = (+textc.value+1) ">
<input type="text" id="textb" name="name" value="0" readonly="readonly" />
<input type="button" value="+" onClick="textb.value = (+textb.value+1);textc.value = (textc.value-1)">Health
<p>
<input type="button" id="minus" value="-" onclick="textm.value = (textm.value-1);textc.value = (+textc.value+1) ">
<input type="text" id="textm" name="name" value="0" readonly="readonly" />
<input type="button" value="+" onClick="textm.value = (+textm.value+1);textc.value = (textc.value-1)">Energy</p>
<p>
<input type="button" id="minus" value="-" onclick="textd.value = (textd.value-1);textc.value = (+textc.value+1) ">
<input type="text" id="textd" name="name" value="0" readonly="readonly" />
<input type="button" value="+" onClick="textd.value = (+textd.value+1);textc.value = (textc.value-1)">Chakra</p>
<p>
<input type="text" id="textc" name="name" readonly="readonly" value="10" />Free points</p>
maxandminonly apply toinput type="number"input type="range"