view src/login.html.luan @ 3:2c63b10781e1

add login
author Franklin Schmidt <fschmidt@gmail.com>
date Thu, 24 Oct 2024 21:43:44 -0600
parents src/index.html.luan@ee1f91e67509
children a49866b52cc2
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 header = Shared.header or error()


return function()
	Io.stdout = Http.response.text_writer()
%>
<!doctype html>
<html>
	<head>
<%		head() %>
	</head>
	<body>
<%		header() %>
		<div content>
			<h1>Login / Register</h1>
			<p>A link to login will be emailed to you.</p>
			<form page onsubmit="ajaxForm('/login.js',this)" action="javascript:">
				<p>
					<label prompt>Your email address</label>
					<input type=email name=email required autofocus>
				</p>
				<p>
					<input type=submit>
				</p>
			</form>
		</div>
	</body>
</html>
<%
end