Quantcast
Channel: Active questions tagged servlets - Stack Overflow
Viewing all articles
Browse latest Browse all 675

Java servlet path [closed]

$
0
0

I make a dynamic web project now.Because it was an exercise, I didn’t use the Maven project.

I use Tomcat 10.1.25.

webapp├── html│├── index.html│└── view.jsp├── META-INF└── WEB-INF

I forward it to View.jsp via GetAll.java.

There is a in the web page generated by View.jsp that can be linked back to the home page.form method="post" action="/html/index.html"But it cannot function properly and 404 errors will appear all the time.uri /MidProject/index.htmlSame thing if I replace the path with "index.html"uri /jsp/index.htmlI later put index.html under the webapp and it worked normally.why is that?Shouldn't the web page generated by jsp use the uri of the Servlet that calls it as the starting point of the path?


Viewing all articles
Browse latest Browse all 675

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>