diff options
Diffstat (limited to 'lbu-commit-html.lsp')
-rw-r--r-- | lbu-commit-html.lsp | 50 |
1 files changed, 9 insertions, 41 deletions
diff --git a/lbu-commit-html.lsp b/lbu-commit-html.lsp index a23b907..fdf44c6 100644 --- a/lbu-commit-html.lsp +++ b/lbu-commit-html.lsp @@ -1,4 +1,6 @@ -<? local form = ... ?> +<? local form = ... +require("viewfunctions") +?> <? --[[ DEBUG INFORMATION io.write("<H1>DEBUGGING</H1><span style='color:red'><H2>DEBUG INFO: CFE</H2>") @@ -6,67 +8,33 @@ io.write(html.cfe_unpack(form)) io.write("</span>") --]] ?> -<? -function displayinfo(myform,tags,viewonly) - io.write("<DL>") - for k,v in pairs(tags) do - if (myform[v]) and (myform[v]["value"]) then - local val = myform[v] - io.write("\t<DT") - if (#val.errtxt > 0) then - val.class = "error" - io.write(" class='error'") - end - io.write(">" .. val.label .. "</DT>\n") - if (viewonly) then - io.write("\t\t<DD>" .. val.value .. "\n") - else - io.write("\t\t<DD>" .. html.form[val.type](val) .. "\n") - end - if (val.descr) and (#val.descr > 0) then io.write("\t\t<P CLASS='descr'>" .. string.gsub(val.descr, "\n", "<BR>") .. "</P>\n") end - if (#val.errtxt > 0) then io.write("\t\t<P CLASS='error'>" .. string.gsub(val.errtxt, "\n", "<BR>") .. "</P>\n") end - io.write("\t\t</DD>\n") - end - end - io.write("</DL>") -end -?> <H1>SYSTEM INFO</H1> +<DL> <? local myform = form.status local tags = { "status", "version", } displayinfo(myform,tags,"viewonly") ?> +</DL> <H2>PROGRAM SPECIFIC OPTIONS/INFORMATION</H2> +<DL> <? local myform = form.status local tags = { "LBU_MEDIA", "ENCRYPTION", } displayinfo(myform,tags,"viewonly") ?> +</DL> <H1>MANAGEMENT</H1> <H2>Save to media</h2> <form name="cmd" action="" method="POST"> +<DL> <? local tags = { "lbusimulate", "lbucommit", "lbucleanmedia", } displayinfo(myform,tags) ?> -</form> - -<DL> -<? if (form.cmdresult) then ?> - <dt>Result of previous action</dt> - <dd><pre><?= form.cmdresult ?></pre></DD> -<? end ?> </DL> - -<? ---[[ 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>") ---]] -?> +</form> |