Mercurial Hosting > luan
annotate website/src/examples/hi.luan @ 1193:9f522cfe0c30
add request to error log
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Mon, 26 Feb 2018 15:43:32 -0700 |
parents | 49cf706c326a |
children |
rev | line source |
---|---|
693
ca169567ce07
module URIs must now include ".luan"
Franklin Schmidt <fschmidt@gmail.com>
parents:
505
diff
changeset
|
1 local Io = require "luan:Io.luan" |
ca169567ce07
module URIs must now include ".luan"
Franklin Schmidt <fschmidt@gmail.com>
parents:
505
diff
changeset
|
2 local Http = require "luan:http/Http.luan" |
382 | 3 |
388 | 4 |
505
7bc63886d4f2
web page modules now return a function
Franklin Schmidt <fschmidt@gmail.com>
parents:
503
diff
changeset
|
5 return function() |
382 | 6 Io.stdout = Http.response.text_writer() |
736 | 7 %> |
1178
49cf706c326a
serve_for_nginx on port 8081
Franklin Schmidt <fschmidt@gmail.com>
parents:
736
diff
changeset
|
8 <!doctype html> |
736 | 9 <html> |
10 <body> | |
11 Hello World | |
12 </body> | |
13 </html> | |
14 <% | |
382 | 15 end |