質問編集履歴
2
title
CHANGED
File without changes
|
body
CHANGED
@@ -5,6 +5,10 @@
|
|
5
5
|
< form action = “相対パス”> の相対パスの部分にいろいろ入れてみましたが、404や405エラーが出てしまいます。
|
6
6
|
(servlet,/servlet,./servlet,../servlet,sample/servlet等入れてみました。)
|
7
7
|
|
8
|
+
URLはhttp://localhost:8080/book/sample.jspで表示できています。
|
9
|
+
フォームに入力後は、
|
10
|
+
http://localhost:8080/book/servletと表示され、405エラーが出てしまいます。(相対パスがform action = “servlet”の場合)
|
11
|
+
|
8
12
|
サーブレットの絶対パス(c:¥work¥pleiades¥workspace¥book¥src¥sample¥ServletA.Java)
|
9
13
|
JSPの絶対パス(c:¥work¥pleiades¥workspace¥book¥WebContent¥sample.jsp)
|
10
14
|
|
1
title
CHANGED
File without changes
|
body
CHANGED
@@ -9,10 +9,14 @@
|
|
9
9
|
JSPの絶対パス(c:¥work¥pleiades¥workspace¥book¥WebContent¥sample.jsp)
|
10
10
|
|
11
11
|
web.xml (WebContent¥WEB-INF内)
|
12
|
+
<servlet>
|
12
13
|
<servlet-name>servlet</servlet-name>
|
13
14
|
<servlet-class>sample.ServletA</servlet-class>
|
15
|
+
</servlet>
|
16
|
+
<servlet-mapping>
|
14
17
|
<servlet-name>servlet</servlet-name>
|
15
18
|
<URL-pattern>/servlet</URL-pattern >
|
19
|
+
</servlet-mapping>
|
16
20
|
|
17
21
|
どなたかご回答いただけたら嬉しいです。
|
18
22
|
よろしくお願い致します。
|