Search
 
SCRIPT & CODE EXAMPLE
 

HTML

allow only positive integer in input type number

<!DOCTYPE html>
<html>
  <head>
    <title>Title of the document</title>
  </head>
  <body>
    <input type="number" name="test_name" min="0" oninput="validity.valid||(value='');">
  </body>
</html>
Comment

PREVIOUS NEXT
Code Example
Html :: css hide image if not found 
Html :: how to show other website inside my website 
Html :: default select option 
Html :: ngfor index 
Html :: add fav icon to browser tab html 
Html :: How can I change the color of one word in HTML? 
Html :: html input only letters 
Html :: fa fa-home 
Html :: mailto tag with line break 
Html :: handlebars js cdn 
Html :: vue js focus ref 
Html :: meta refresh 
Html :: django template tags background-image 
Html :: action button dropdown 
Html :: doctype html charset utf-8 
Html :: axonivy sub component 
Html :: laravel old request html div add style 
Html :: how to limit characters in contenteditable div 
Html :: bold text in input field 
Html :: html if en change to ltr 
Html :: align right tailwind 
Html :: select2 bootstrap modal issue 
Html :: html close window button 
Html :: html form validation for phone numbers 
Html :: render text as html react 
Html :: vue js v-for with index 
Html :: html error page template 
Html :: pyscript boilerplate 
Html :: html fax 
Html :: no blank space html 
ADD CONTENT
Topic
Content
Source link
Name
3+9 =