eclipse错误:The import javax.servlet.http.HttpServletRequest cannot be resolved解决

核心提示:错误: The import javax.servlet.http.HttpServletRequest cannot be resolved 解决: 1、这是因为工程里面web-inf/lib目录下少了包:Package javax.servlet.http引起的; (包的介绍可参见: http://java.sun.com/products/servlet/2.5/docs/servlet-2_5-m
错误:
The import javax.servlet.http.HttpServletRequest cannot be resolved

解决:

1、这是因为工程里面web-inf/lib目录下少了包:Package javax.servlet.http引起的;

(包的介绍可参见:http://java.sun.com/products/servlet/2.5/docs/servlet-2_5-mr2/index.html

2、在tomcat(本人的当前版本6.0.18)lib目录servlet-api.jar,将其copy到工程里面web-inf/lib目录下;

http://ajava.org/exep/eclipse/16545.html

 

发表评论

电子邮件地址不会被公开。 必填项已用*标注