aboutsummaryrefslogtreecommitdiffstats
path: root/views/index.erb
diff options
context:
space:
mode:
authorTeddy Wing2015-12-08 01:26:57 -0500
committerTeddy Wing2015-12-08 01:26:57 -0500
commita6c33077c7ac124e6c4db6ad272ab67226aba354 (patch)
tree9d4e7be8afa09ac666a9b70f170391aaf25bdf3c /views/index.erb
parent61e3141fb526e6a967e9eee01de4fae474b4e9cc (diff)
downloadRuby-Web-Sessions-Exercise-a6c33077c7ac124e6c4db6ad272ab67226aba354.tar.bz2
Add layout.erb
Move boilerplate code from `index.erb` into `layout.erb` to allow us to use it in additional templates.
Diffstat (limited to 'views/index.erb')
-rw-r--r--views/index.erb37
1 files changed, 14 insertions, 23 deletions
diff --git a/views/index.erb b/views/index.erb
index 4425304..ff06792 100644
--- a/views/index.erb
+++ b/views/index.erb
@@ -1,24 +1,15 @@
-<!doctype html>
-<html lang="en">
-<head>
- <meta charset="utf-8">
- <title>Ruby Session Exercise</title>
-</head>
-<body>
- <h1>Login</h1>
+<h1>Login</h1>
+
+<form action="." method="post">
+ <div>
+ Username: <input type="text" name="username" />
+ </div>
- <form action="." method="post">
- <div>
- Username: <input type="text" name="username" />
- </div>
-
- <div>
- Password: <input type="password" name="password" />
- </div>
-
- <div>
- <input type="submit" value="Login" />
- </div>
- </form>
-</body>
-</html>
+ <div>
+ Password: <input type="password" name="password" />
+ </div>
+
+ <div>
+ <input type="submit" value="Login" />
+ </div>
+</form>