Add exo4 code.
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Tue, 10 Apr 2018 13:17:59 +0000 (15:17 +0200)
committerJérôme Benoit <jerome.benoit@piment-noir.org>
Tue, 10 Apr 2018 13:17:59 +0000 (15:17 +0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
ROOT/exo4/META-INF/context.xml [new file with mode: 0644]
ROOT/exo4/bienvenue.jsp [new file with mode: 0644]
ROOT/exo4/date.jsp [new file with mode: 0644]
ROOT/exo4/include.jsp [new file with mode: 0644]
ROOT/exo4/script-page-contenttype-html.jsp [new file with mode: 0644]
ROOT/exo4/script-page-contenttype-xml.jsp [new file with mode: 0644]

diff --git a/ROOT/exo4/META-INF/context.xml b/ROOT/exo4/META-INF/context.xml
new file mode 100644 (file)
index 0000000..00e2ff6
--- /dev/null
@@ -0,0 +1,2 @@
+<Context path=""
+       antiResourceLocking="false" />
diff --git a/ROOT/exo4/bienvenue.jsp b/ROOT/exo4/bienvenue.jsp
new file mode 100644 (file)
index 0000000..1f0b32d
--- /dev/null
@@ -0,0 +1,5 @@
+<html>
+<body>
+    Bienvenue au cours d'applications web
+</body>
+</html>
diff --git a/ROOT/exo4/date.jsp b/ROOT/exo4/date.jsp
new file mode 100644 (file)
index 0000000..8634bba
--- /dev/null
@@ -0,0 +1,10 @@
+<%@ page import="java.io.*, java.util.*, javax.servlet.*" %>
+<html>
+<body>
+    Aujourd'hui est le
+    <%
+        Date date = new Date();
+        out.print(date.toString());
+    %>
+</body>
+</html>
diff --git a/ROOT/exo4/include.jsp b/ROOT/exo4/include.jsp
new file mode 100644 (file)
index 0000000..6e7133e
--- /dev/null
@@ -0,0 +1 @@
+<%@ include file="bienvenue.jsp" %>
diff --git a/ROOT/exo4/script-page-contenttype-html.jsp b/ROOT/exo4/script-page-contenttype-html.jsp
new file mode 100644 (file)
index 0000000..5d07fde
--- /dev/null
@@ -0,0 +1,8 @@
+<%@ page contentType="text/html; charset=ISO-8859-1" %>
+<html>
+<body>
+
+    Bonjour
+
+</body>
+</html>
diff --git a/ROOT/exo4/script-page-contenttype-xml.jsp b/ROOT/exo4/script-page-contenttype-xml.jsp
new file mode 100644 (file)
index 0000000..d7a72a3
--- /dev/null
@@ -0,0 +1,8 @@
+<%@ page contentType="text/xml, charset=ISO-8859-1" %>
+<html>
+<body>
+
+    Bonjour
+
+</body>
+</html>