form表单提交数据到后台java

jsp里面的代码 <form name="form1" method="post" action="/servlet/Login">

xml配置
<servlet>
<description>This is the description of my J2EE component</description>
<display-name>This is the display name of my J2EE component</display-name>
<servlet-name>Login</servlet-name>
<servlet-class>com.hospital.Login</servlet-class>
</servlet>

<servlet-mapping>
<servlet-name>Login</servlet-name>
<url-pattern>/servlet/Login</url-pattern>
文件位置

为什么会出现这个页面

jsp中的action路径的前面加上/hospital,这是你整个项目的路径追问

修改了后显示这个

温馨提示:答案为网友推荐,仅供参考
第1个回答  2015-06-16
你应该先访问那个jsp啊
相似回答