From 02f08e3420245cb727783f5abe460d336f135459 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Mon, 3 Feb 2014 21:55:41 +0000 Subject: Cleanup HTML including removing DL/DT/DD, use tablesorter where possible, and use lowercase tags --- tcpproxy-listsmtpentries-html.lsp | 54 +++++++++++++++++++++++++-------------- tcpproxy-listsmtpfiles-html.lsp | 47 +++++++++++++++++++++++----------- tcpproxy-smtpstatus-html.lsp | 12 ++++----- 3 files changed, 73 insertions(+), 40 deletions(-) diff --git a/tcpproxy-listsmtpentries-html.lsp b/tcpproxy-listsmtpentries-html.lsp index 6fffd1b..228aa76 100644 --- a/tcpproxy-listsmtpentries-html.lsp +++ b/tcpproxy-listsmtpentries-html.lsp @@ -3,32 +3,48 @@ htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> + + + + + + <% htmlviewfunctions.displaycommandresults({"editsmtpentry", "delsmtpentry"}, session) %> -

Interface Entries

-
- - - - - - - +

Interface Entries

+
ActionInterfaceIP AddressCommand Entry
+ + + + + + + <% for i,interface in ipairs(view.value) do %> - - + - - - - + + + + + <% end %> -
ActionInterfaceIP AddressCommand Entry
+
<% if viewlibrary.check_permission("editsmtpentry") then %> <%= html.link{value=page_info.script..page_info.prefix..page_info.controller.."/editsmtpentry?ipaddr="..(interface.ipaddr or interface.interface).."&redir="..page_info.orig_action, label="Edit "} %> <% end %> <% if viewlibrary.check_permission("delsmtpentry") then %> <%= html.link{value=page_info.script..page_info.prefix..page_info.controller.."/delsmtpentry?submit=true&ipaddr="..(interface.ipaddr or interface.interface), label="Delete "} %> <% end %> - <%= html.html_escape(interface.interface) %><%= html.html_escape(interface.ipaddr) %><%= html.html_escape(interface.cmd) %>
<%= html.html_escape(interface.interface) %><%= html.html_escape(interface.ipaddr) %><%= html.html_escape(interface.cmd) %>
- -
+ diff --git a/tcpproxy-listsmtpfiles-html.lsp b/tcpproxy-listsmtpfiles-html.lsp index 8918a7e..b5e479a 100644 --- a/tcpproxy-listsmtpfiles-html.lsp +++ b/tcpproxy-listsmtpfiles-html.lsp @@ -3,35 +3,52 @@ htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> + + + + + + <% htmlviewfunctions.displaycommandresults({"editsmtpfile", "delsmtpfile"}, session) %> <% htmlviewfunctions.displaycommandresults({"createsmtpfile"}, session, true) %> -

Files

-
- - - - - +

Files

+
ActionFile
+ + + + + <% for i,file in ipairs(view.value) do %> - - + - - + + + <% end %> -
ActionFile
+
<% if viewlibrary.check_permission("editsmtpfile") then %> <%= html.link{value=page_info.script..page_info.prefix..page_info.controller.."/editsmtpfile?filename="..file.."&redir="..page_info.orig_action, label="Edit "} %> <% end %> <% if viewlibrary.check_permission("delsmtpfile") then %> <%= html.link{value=page_info.script..page_info.prefix..page_info.controller.."/delsmtpfile?submit=true&filename="..file, label="Delete "} %> <% end %> - <%= html.html_escape(file) %>
<%= html.html_escape(file) %>
-
+ <% if viewlibrary and viewlibrary.dispatch_component and viewlibrary.check_permission("createsmtpfile") then local createform = viewlibrary.dispatch_component("createsmtpfile", nil, true) %> -

<%= html.html_escape(createform.label) %>

+

<%= html.html_escape(createform.label) %>

<% createform.action = page_info.script .. page_info.prefix .. page_info.controller .. "/createsmtpfile" htmlviewfunctions.displayform(createform) diff --git a/tcpproxy-smtpstatus-html.lsp b/tcpproxy-smtpstatus-html.lsp index d5f4a46..7edf5e0 100644 --- a/tcpproxy-smtpstatus-html.lsp +++ b/tcpproxy-smtpstatus-html.lsp @@ -6,17 +6,17 @@ html = require("acf.html") <% htmlviewfunctions.displaycommandresults({"editsmtpentry", "delsmtpentry", "editsmtpfile", "delsmtpfile"}, session) %> <% htmlviewfunctions.displaycommandresults({"createsmtpfile"}, session, true) %> -

SMTP Proxy Status

-
+

SMTP Proxy Status

<% htmlviewfunctions.displayitem(view.value.version) if view.value.version and view.value.version.errtxt and viewlibrary.check_permission("apk-tools/apk/install") then %> -
Install package
-
" method="POST"> +

Install package

+
+ " method="post"> -
+ + <% end %> -
<% if viewlibrary and viewlibrary.dispatch_component then viewlibrary.dispatch_component("listsmtpentries") -- cgit v1.2.3