diff options
Diffstat (limited to 'dnscache-expert-html.lsp')
-rw-r--r-- | dnscache-expert-html.lsp | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/dnscache-expert-html.lsp b/dnscache-expert-html.lsp new file mode 100644 index 0000000..4f77e5e --- /dev/null +++ b/dnscache-expert-html.lsp @@ -0,0 +1,58 @@ +<? local form = ... +require("viewfunctions") +?> +<? +--[[ DEBUG INFORMATION +io.write("<H1>DEBUGGING</H1><span style='color:red'><H2>DEBUG INFO: CFE</H2>") +io.write(html.cfe_unpack(form)) +io.write("</span>") +--]] +?> + +<H1>SYSTEM INFO</H1> +<DL> +<? +local myform = form.status +local tags = { "status", "version", "autostart", } +displayinfo(myform,tags,"viewonly") +?> +</DL> + +<form name="myform" action="" method="POST"> +<h1>CONFIGURATION</h1> +<H2>Expert config</H2> +<h3>File details</h3> +<DL> +<? +local myform = form.file +local tags = { "filename", "filesize", "mtime", "sumerrors", } +displayinfo(myform,tags,"viewonly") +?> +</DL> + +<H3>FILE CONTENT</H3> +<? +local myform = form.file +io.write(html.form[myform.filecontent.type](myform.filecontent)) +?> + +<H2>SAVE AND APPLY ABOVE SETTINGS</H2> +<DL> +<? +local tags = { "cmdsave", } +displayinfo(myform,tags) +?> +</DL> + +<? +-- Management buttons +local myform = form.management +local tags = { "start", "stop", "restart" } +if (myform) then + io.write("<H1>MANAGEMENT</H1>\n<DL>") + displaymanagement(myform,tags) + io.write("</DL>") +end +?> +</form> + |