When the input field gets focus, replace its current value with an empty string.
<input type="text" onfocus="this.value=''" value="The text">
Example 1: Clears Input Field on Focus
Example 2: Clears Input Field with a Button
I hope you get an idea about jquery reset input value.
I would like to have feedback on my infinityknow.com blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.
Here are some more FAQ related to this Article: