I am performing validation of inputted data such as email, password, name, etc. But I am already stuck on the first stage of validation which is to check if User entered not
Unless you're planning to use your form for uploading a file, you don't need to specify the encoding type of "multipart/form-data".
<form method="POST" action="signup">
<input type="text" name="email" placeholder="tonystark@mail.com">
<input type="submit" value="Submit">
</form>
The last paragraph in your link states:
"When using enctype="multipart/form-data", all parameters are encoded in the request body. That means that request.getParameter(...) will return null for all posted parameters then."
Input type: email
Email is an html5 input type. How To Use The New Email, URL, and Telephone Input Types.
Since it is a multipart/form-data (usually used for the puropose of uploading one/more file(s)) form the request.getParameter()
method will always return null
.
You can try
<form method="POST" action="signup" enctype="application/x-www-form-urlencoded">
Or completely remove the enctype
parameter.
Some references in another SO question.
How to upload files to server using JSP/Servlet?