Stay With us
3 new comments

beginner
new

Help & Settings
About
Help
Tips

Check for Null values in HTML input field

I have a input field created a simpe text box in html. Here is my html code.

<input type="text" name="username" id="username" class="form-control" placeholder="Username..." />

As i am new to web, so i have not enough knowledge of js or jquery. Is there any way in html so that if this text box is empty than the form should not be submitted. The user should get a message to fill the field correctly. How can i do this in html to check input box?

Thanks!

Matt
75 Points

(1) Replies

Please login or register to Comment or Answer