
HTTP Status 404
Publicado por Adrian (10 intervenciones) el 13/02/2007 05:03:36
Estoy haciendo un html que invoca a un jsp este esta dentro del WEB-INF y a su vez dentro de un folder llamado mypacke. el tema es que me aparece el siguiente error. Les paso los dos archivos a ver si alguien tiene una idea
gracias
adrian
HTTP Status 404 - /mypackage.Categorie.jsp
--------------------------------------------------------------------------------
type Status report
message /mypackage.Categorie.jsp
description The requested resource (/mypackage.Categorie.jsp) is not available.
Categories.html
gracias
adrian
HTTP Status 404 - /mypackage.Categorie.jsp
--------------------------------------------------------------------------------
type Status report
message /mypackage.Categorie.jsp
description The requested resource (/mypackage.Categorie.jsp) is not available.
Categories.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
<html>
<head>
<title>Categories</title>
</head>
<body>
<h1>Categories</h1>
<p>
<form ACTION="/BookStore/mypackage.Categorie.jsp">
A simple example to find information about a place in the United Kingdom.<br>
Enter place name
<input type=text name=place><br>
<input type=submit value="Search database">
</form>
<p>
</body>
</html>
Categorie.jsp
<html>
<head>
<%@ page
package mypackage;
import = "java.io.*"
import = "java.lang.*"
import = "java.sql.*"
import = "java.lang.Object.*";
%>
<title>JSP Example 2 </title>
</head>
<body>
<h1>JSP Example 3</h1>
<%
String place;
Connection dbconn;
ResultSet results;
PreparedStatement sql;
try
{
Class.forName("com.mysql.jdbc.Driver");
try
{
int CategorieId;
String Name;
String Coments;
boolean doneheading = false;
dbconn = DriverManager.getConnection("jdbc:mysql://localhost/ryersonbooks","root","");
place = request.getParameter("place");
sql = dbconn.prepareStatement("SELECT * FROM Categories WHERE Name = '" + place + "'");
results = sql.executeQuery();
while(results.next())
{
if(! doneheading)
{
out.println("<table border=2>");
doneheading = true;
}
CategorieId = results.getInt("CategorieId");
Name = results.getString("Name");
Coments = results.getString("Coments");
out.println("<tr><td>" + CategorieId);
out.println("<td>" + Name);
out.println("<td>" + Coments);
}
if(doneheading)
{
out.println("</table>");
}
else
{
out.println("No matches for " + place);
}
}
catch (SQLException s)
{
out.println("SQL Error<br>");
}
}
catch (ClassNotFoundException err)
{
out.println("Class loading error");
}
%>
</body>
</html>
Valora esta pregunta


0