I have a simple servlet which is supposed to fetch a HTML from my project and display it using servlets. The HTML is displaying fine, but the image is not being recognized and returning a 404.
Here is the snippet from the HTML which is giving me a 404:
<a href="index.html"><img src="WEB-INF/images/logo.png" alt=""/></a>
Error:
Request URL:http://localhost:8080/JPA/images/logo.png
Request Method:GET
Status Code:404 Not Found
Here is my servlet code (Landingpage.java):
request.getRequestDispatcher("WEB-INF/index.html").include(request, response);
The project's name is JPA, and the HTML + image is under WEB-INF. The image specifically is under a folder called "image" as you can see on the screenshot.
All help is appreciated. Thank you.