Mercurial Hosting > linkmystyle
view src/login.html.luan @ 0:8f4df159f06b
start public repo
| author | Franklin Schmidt <fschmidt@gmail.com> |
|---|---|
| date | Fri, 11 Jul 2025 20:57:49 -0600 |
| parents | |
| children |
line wrap: on
line source
local Luan = require "luan:Luan.luan" local error = Luan.error local Io = require "luan:Io.luan" local Http = require "luan:http/Http.luan" local Shared = require "site:/lib/Shared.luan" local head = Shared.head or error() local page_header = Shared.page_header or error() local footer = Shared.footer or error() local password_input = Shared.password_input or error() return function() Io.stdout = Http.response.text_writer() %> <!doctype html> <html lang="en"> <head> <% head() %> <title>Link My Style</title> <style> div[right_of_page] { background-image: url(/images/shirts.jpg); } div[forgot] { text-align: center; margin-top: 10px; } div[register] { text-align: center; margin-top: 20px; } </style> </head> <body> <form page onsubmit="ajaxForm('/login.js',this)" action="javascript:"> <% page_header() %> <div> <h1>Log in</h1> <input type=text required name=username placeholder="Username"> <div error=username></div> <% password_input() %> <div error=password></div> <button type=submit big>Log in</button> <div forgot><a href="/forgot.html">Forgot username or password?</a></div> <div register>Don't have a Link My Style account? <a href="/register.html">Create one</a></div> </div> <% footer() %> </form> <div right_of_page></div> </body> </html> <% end
