I have a Struts 2 project with following directory structure. But when I try to run this project using Eclipse on Tomcat 7, it gives me 404 error.
Struts.xml
:
<?xml version="1.0" encoding="UTF-8"?>
<struts>
<action name="login" class="com.actions.LoginAction" method="execute">
<result name="success">/jsp/login.jsp</result>
</action>
</struts>
login.jsp
:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Login Page</title>
</head>
<body>
<s:form action="login" method="post">
Login name : <input type="text" value="name"/>
</s:form>
</body>
</html>
On running at path http://localhost:8080/StrutsPro/jsp/login.jsp
, it gives HTTP 404 error.