2
0

env.lua 699 B

1234567891011121314151617181920212223242526
  1. -- This file should be executed before any script in this directory
  2. -- according to the configuration (cgilua/conf.lua).
  3. pcall (cgilua.enablesession)
  4. local put, mkurlpath = cgilua.put, cgilua.mkurlpath
  5. cgilua.addclosefunction (function ()
  6. put [[
  7. <p>
  8. <small>
  9. <a href="test_main.html">Main</a>]]
  10. for _, test in {
  11. { "Get", "test_main.lua", {ab = "cd", ef = "gh"} },
  12. { "Cookies", "test_cookies.lua", },
  13. { "FileSystem", "test_fs.lua", },
  14. { "Libraries", "test_lib.lua", },
  15. { "Session", "test_session.lua", },
  16. { "Variables", "test_variables.lp", },
  17. } do
  18. put (string.format (' &middot; <a href="%s">%s</a>',
  19. mkurlpath (test[2], test[3]), test[1]))
  20. end
  21. put [[
  22. </small>]]
  23. end)