Happy Holloween everyone! Despite busy schedule due to a holiday, I would love to share this solution on How to Handle Maxlength HTML5 Input Type Number. Basically, Maxlength will only work for strings. But using the element of type “number” are only used to let the user enter a number. It a built-in validation to reject non-numerical entries.
The Code snippet below that I found on the internet is really working. This time I will share this to all especially those individuals who encounter the same problem.
<label class="col-md-4 control-label" for=
"guardianAdd">Contact No. </label>
<input class="form-control input-sm" id="guardianAdd" name="guardianAdd"
type="number" placeholder="Guardian/Parent Contact Number" required
Hopefully, this would really help you a lot. And If you have any questions or suggestion about this topic please feel free to contact me on our contact page.
The related article you may like.