File: tfcgi1.lua

package info (click to toggle)
lua-cgi 6.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 956 kB
  • sloc: javascript: 2,216; makefile: 25
file content (10 lines) | stat: -rwxr-xr-x 360 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
-- $Id: tfcgi1.lua,v 1.1 2004/03/25 19:31:05 tomas Exp $
lfcgi.stdout:write"Content-type: text/html\n\n"

for i,v in pairs{"QUERY_STRING", } do
	lfcgi.stdout:write (string.format ("%s = %s", v, os.getenv(v) or ' '))
end
lfcgi.stdout:write "<br>\n"

local post_data = lfcgi.stdin:read"*a"
lfcgi.stdout:write (string.format ("post_data = {%s}", post_data))