I am learning maven these days. During making Web application it shows error.
When I add servlets in the source location and add these changes in the web.xml. It shows package missing errors.
My imports in code are :-
- import java.io.*;
- import javax.servlet.*;
- import javax.servlet.http.*;
When I write mvn compile in command prompt in windows. It shows errors.
Errors are as follows:-
- package javax.servlet does not exists.
- package javax.servlet.http doeas not exist.
- Some errors related to above two.
Help me.Looking for your kind response.
You probably just have to add the dependency to your web.xml.
check here maybe: http://mvnrepository.com/artifact/javax.servlet/servlet-api