diff options
author | Ted Trask <ttrask01@yahoo.com> | 2014-02-03 21:48:48 +0000 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2014-02-03 21:48:48 +0000 |
commit | e5f62555031d500d50405ba395e330223ac28e9f (patch) | |
tree | f2676b4768a95561597ca746afc400eeaffeed7c /provisioning-listfiles-html.lsp | |
parent | cd46e0528fdf0fd412416c91b40551140b8f2724 (diff) | |
download | acf-provisioning-e5f62555031d500d50405ba395e330223ac28e9f.tar.bz2 acf-provisioning-e5f62555031d500d50405ba395e330223ac28e9f.tar.xz |
Cleanup HTML including removing DL/DT/DD, use tablesorter where possible, and use lowercase tags
Diffstat (limited to 'provisioning-listfiles-html.lsp')
-rw-r--r-- | provisioning-listfiles-html.lsp | 34 |
1 files changed, 26 insertions, 8 deletions
diff --git a/provisioning-listfiles-html.lsp b/provisioning-listfiles-html.lsp index e94b207..cc9e02a 100644 --- a/provisioning-listfiles-html.lsp +++ b/provisioning-listfiles-html.lsp @@ -3,19 +3,37 @@ htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> +<script type="text/javascript"> + if (typeof jQuery == 'undefined') { + document.write('<script type="text/javascript" src="<%= html.html_escape(page_info.wwwprefix) %>/js/jquery-latest.js"><\/script>'); + } +</script> + +<script type="text/javascript"> + if (typeof $.tablesorter == 'undefined') { + document.write('<script type="text/javascript" src="<%= html.html_escape(page_info.wwwprefix) %>/js/jquery.tablesorter.js"><\/script>'); + } +</script> + +<script type="text/javascript"> + $(document).ready(function() { + $("#list").tablesorter({widgets: ['zebra']}); + }); +</script> + <% htmlviewfunctions.displaycommandresults({"editfile"}, session) %> <h1>Provisioning Script Files</h1> -<DL><TABLE> - <TR style="background:#eee;font-weight:bold;"> - <TD style="padding-right:20px;white-space:nowrap;text-align:left;" class="header">File</TD> - <TD style="padding-right:20px;white-space:nowrap;text-align:left;" class="header">Size</TD> - <TD style="white-space:nowrap;text-align:left;" class="header">Last Modified</TD> - </TR> - +<table id="list" class="tablesorter"><thead> + <tr> + <th>File</th> + <th>Size</th> + <th>Last Modified</th> + </tr> +</thead><tbody> <% for k,v in ipairs( view.value ) do io.write( "<tr><td><a href=\"" .. html.html_escape(page_info.script .. page_info.prefix .. page_info.controller) .. "/editfile?filename=" .. html.html_escape(v.filename) .. "&redir=" .. html.html_escape(page_info.orig_action) .. "\">" .. html.html_escape(v.filename) .. "</a></td><td>" .. html.html_escape(v.size) .."</td><td>" .. html.html_escape(v.mtime) .."</td></tr>\n" ) end %> -</TABLE></DL> +</tbody></table> |