dimanche 12 avril 2015

http status 404 hello.jsp (apache tomcat 6)

im new to using apache and spring framework and i've been using this tutorial for learning: http://docs.spring.io/docs/Spring-MVC-step-by-step/part1.html i made an .jsp file however my browser tells me "The requested resource is not available."


the .jsp file is pretty simple



<html>
<head><title>Hello :: Spring Application</title></head>
<body>
<h1>Hello - Spring Application</h1>
<p>Greetings.</p>
</body>
</html>


entering http://localhost:8080/project/hello.htm gives me a 404. my web.xml file:



<?xml version="1.0" encoding="UTF-8"?>

<web-app version="2.4"
xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://ift.tt/ra1lAU"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" >

<servlet>
<servlet-name>project</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>

<servlet-mapping>
<servlet-name>project</servlet-name>
<url-pattern>*.htm</url-pattern>
</servlet-mapping>

<welcome-file-list>
<welcome-file>
index.jsp
</welcome-file>
</welcome-file-list>

</web-app>


any idea how to fix this?


Aucun commentaire:

Enregistrer un commentaire