【发布时间】:2015-09-01 16:25:01
【问题描述】:
每当我想在 Tomcat7.0 上从 eclipse 运行 servlet 时,服务器启动都会失败。我从一个星期开始练习 jsp 和 servlet,直到今天早上一切都很好,突然我的系统从那时起意外关闭,我面临这个问题。我尝试了所有可能的方法,例如删除服务器并创建新服务器等,但最终This instruction helps me
You need to copy the required commons jars into your /WEB-INF/lib folder as well.
commons-io-2.4.jar
commons-fileupload-1.3.1.jar
The reason is that just adding the jar dependencies to your Eclipse project's build path does not make them automatically available on Tomcat. Since, the dependencies are missing (not found in the lib folder) your web app's deployment fails.
我还有一个问题和一个问题。问题是,我是否必须在我所有项目的 /WEB-INF/lib 文件夹中添加上面提到的两个 Jar 文件?问题是虽然我的服务器运行没有任何错误,但它无法运行 servlet 文件。我得到这个错误。它只发生在 servlet 上,jsp 或 html 文件没有问题。我尝试创建三个以上的新项目进行测试,但结果与以下相同。
HTTP Status 404 - /Register
--------------------------------------------------------------------------------
type Status report
message /Register
description The requested resource is not available.
【问题讨论】:
-
您使用了错误的关键字进行搜索。这是可以接受的骗局吗? stackoverflow.com/questions/11731377/…
标签: java eclipse jsp tomcat servlets