Search
 
SCRIPT & CODE EXAMPLE
 

HTML

javascript how to set a textbox value to nothing

<input id="text">
<button onclick="myFunction()">Run</button>
<script>
  function myFunction() {
    document.getElementById("text").value = "";
  }
</script>
Comment

PREVIOUS NEXT
Code Example
Html :: html element hover helptext 
Html :: hide navbar bootstrap 5 
Html :: laravel route regular expression constraints 
Html :: html spacing 
Html :: html5 datalist 
Html :: html login and registration form 
Html :: how to show code with html 
Html :: theme colur in html 
Html :: Horizontal Scrolling Bopostrap 
Html :: html js script 
Html :: unselectable input field 
Html :: section tag in html 
Html :: html email regex 
Html :: html table colspan and rowspan 
Html :: bootstrap nav nav tabs float right 
Html :: img tag 
Html :: how to add video in html 
Html :: html ms-text-size-adjust 
Html :: filter vhtml vue 
Html :: how to echo data into an option tag as a link 
Html :: how to import jquery modular 
Html :: how to make the border invisible in html 
Html :: Hide table column using JavaScript 
Html :: html hex color 
Html :: which is right <hr or <hr/ in html 
Html :: $ html 
Html :: Html div element animation example 
Html :: input type checkbox and hide checkbox 
Html :: tailwind css width 50 percent 
Html :: colors bootstrap 
ADD CONTENT
Topic
Content
Source link
Name
1+4 =