Mercurial Hosting > freedit
comparison src/logout.html.luan @ 3:fc3ee39d7764
login
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sun, 19 Jun 2022 20:47:31 -0600 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
2:fc2383eb48a9 | 3:fc3ee39d7764 |
---|---|
1 local Luan = require "luan:Luan.luan" | |
2 local error = Luan.error | |
3 local Io = require "luan:Io.luan" | |
4 local Http = require "luan:http/Http.luan" | |
5 local Shared = require "site:/lib/Shared.luan" | |
6 local head = Shared.head or error() | |
7 local header = Shared.header or error() | |
8 local footer = Shared.footer or error() | |
9 local Forum = require "site:/lib/Forum.luan" | |
10 local forum_title = Forum.title or error() | |
11 | |
12 | |
13 return function() | |
14 Http.response.remove_cookie("user") | |
15 Http.response.remove_cookie("password") | |
16 Http.request.cookies.user = nil | |
17 Http.request.cookies.password = nil | |
18 Io.stdout = Http.response.text_writer() | |
19 %> | |
20 <!doctype html> | |
21 <html> | |
22 <head> | |
23 <% head() %> | |
24 <title><%=forum_title%> - Logout</title> | |
25 </head> | |
26 <body> | |
27 <% header() %> | |
28 <div content> | |
29 <h1>Logout</h1> | |
30 | |
31 <p>You have been logged out.</p> | |
32 </div> | |
33 <% footer() %> | |
34 </body> | |
35 </html> | |
36 <% | |
37 end |