Firefox 中的 HTML5 输入类型"number"
htmljavascriptprogramming scripts
Firefox 不支持输入类型 number 的 min 属性,但它在 Google Chrome 中可以正常工作。
示例
让我们看一个例子 −
<!DOCTYPE html> <html> <head> <title>HTML input number</title> </head> <body> <form action = "" method = "get"> Mention any number between 1 to 10 <input type = "number" name = "num" min = "1" max = "10"><br> <input type = "submit" value = "Submit"> </form> </body> </html>