diff options
| author | Stefan Suhren <suhren.stefan@fh-swf.de> | 2015-11-15 22:57:39 +0100 |
|---|---|---|
| committer | Stefan Suhren <suhren.stefan@fh-swf.de> | 2015-11-15 22:57:39 +0100 |
| commit | 120ee15ae5d7a6d8e184e6580e535112ec1e40cc (patch) | |
| tree | 4cf3b2e37d754c0cfb9b2aec1adf382beb961aa1 /WebContent | |
| parent | c58001fdf1defd03ff30cd9c39160b03eec02434 (diff) | |
| download | FIT-120ee15ae5d7a6d8e184e6580e535112ec1e40cc.tar.gz FIT-120ee15ae5d7a6d8e184e6580e535112ec1e40cc.zip | |
Build a login that forwards to a JSP
Diffstat (limited to 'WebContent')
| -rw-r--r-- | WebContent/LoginFormWithJpaAndJsp.jsp | 16 | ||||
| -rw-r--r-- | WebContent/LoginSuccess.jsp | 14 |
2 files changed, 30 insertions, 0 deletions
diff --git a/WebContent/LoginFormWithJpaAndJsp.jsp b/WebContent/LoginFormWithJpaAndJsp.jsp new file mode 100644 index 0000000..fa89d8f --- /dev/null +++ b/WebContent/LoginFormWithJpaAndJsp.jsp @@ -0,0 +1,16 @@ +<%@ page language="java" contentType="text/html; charset=UTF-8" + pageEncoding="UTF-8"%> +<!DOCTYPE html> +<html> +<head> +<meta charset="utf-8" /> +<title>Login</title> +</head> +<body> + <form action="LoginServletWithJpaAndJsp" method="post"> + <label for="username">Username:</label><input type="text" name="username" id="username"><br> + <label for="password">Password:</label><input type="password" name="password" id="password"><br> + <input type="submit"><input type="reset"> + </form> +</body> +</html>
\ No newline at end of file diff --git a/WebContent/LoginSuccess.jsp b/WebContent/LoginSuccess.jsp new file mode 100644 index 0000000..d4fe5de --- /dev/null +++ b/WebContent/LoginSuccess.jsp @@ -0,0 +1,14 @@ +<%@ page language="java" contentType="text/html; charset=UTF-8" + pageEncoding="UTF-8"%> +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<!DOCTYPE html> +<html> +<head> +<meta charset="utf-8" /> +<title>Welcome</title> +</head> +<body> + <h1>Welcome <%= session.getAttribute("username") %><br> + <a href="LoginFormWithJpaAndJsp.jsp">Retry</a> +</body> +</html>
\ No newline at end of file |
