0
votes

I'm working with eclipse and I created a project, I put a test.html and test.jsp file in the root folder. In the URL of the Google Chrome I put this:

http://localhost:8080/project/test.html Error 404

http://localhost:8080/project/test.jsp Works (hello world!)

What is happening?

2
Have you verified that test.html actually exists in the file system? Make sure you save all your files in eclipse before publishing. Also if you just added the file, with eclipse sometimes you have to restart the server after publishing, although usually that process is automatic.Jason C
I restarted.. doesn't worksSequoya
If it's a dynamic web project, then both test.html and test.jsp should be accessed normally if put directly under WebContent.Hussein Terek
You should be able to check where your files are ending up at <Your Eclipse Workspace>\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebappsAlessandro Scarlatti
@JasonC Faceted Project Problem - Target runtime Apache Tomcat v7.0 is not defined.Sequoya

2 Answers

2
votes

Double check if your test.html exists under this path: "Workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\project"

If exists, then it should be accessed normally, if not then you have to clean/build your application correctly or even try to restart eclipse.

0
votes

Based on your follow-up comments about the custom Tomcat install and the project error message, it sounds like you either don't have Eclipse properly configured to use your Tomcat server, or you don't have your project associated with the Tomcat server you've set up, and so perhaps your changes arent being deployed properly. See if that issue has a quick fix suggestion (right click it) or go through your project settings and verify your selected server runtime. Sorry on phone can't give specific instructions.