Commit cd1c3f6e authored by Ted Trask's avatar Ted Trask
Browse files

Some more tablesorter cleanup - removal of styles and specifying sorters

parent 9daf92db
......@@ -45,7 +45,7 @@ end
<% else %>
<TABLE id="adhocresult" class="tablesorter">
<THEAD>
<TR style="font-weight:bold;">
<TR>
<% for i,name in ipairs(form.value.names.value) do %>
<TH class="header"><%= html.html_escape(name) %></TH>
<% end %>
......
......@@ -17,7 +17,7 @@
<script type="text/javascript">
$(document).ready(function() {
<% if data.value.groupby.value == "clientip" then %>
$("#audit").tablesorter({headers: {0:{sorter:'ipAddress'}}, widgets: ['zebra']});
$("#audit").tablesorter({headers: {0:{sorter:'ipAddress'}, 1:{sorter:'digit'}, 2:{sorter:'digit'}, 3:{sorter:'digit'}, 4:{sorter:'digit'}, 5:{sorter:'digit'}, 6:{sorter:'digit'}}, widgets: ['zebra']});
<% else %>
$("#audit").tablesorter({widgets: ['zebra']});
<% end %>
......@@ -35,7 +35,7 @@
<H1><%= html.html_escape(data.label) %></H1>
<DL>
<TABLE id="audit" class="tablesorter"><THEAD>
<TR style="font-weight:bold;">
<TR>
<TH><% if data.value.groupby.value == "clientip" then %>Client IP<% else %>User ID<% end %></TH>
<TH>Total Requests</TH>
<TH>Flagged Requests</TH>
......
......@@ -95,9 +95,6 @@ end
<% local subdata, pagedata = htmlviewfunctions.paginate(data.value.log.value, page_info.clientdata, 200) %>
<style type="text/css">
#content table { border-collapse: collapse; width: 100%; }
#content table td { border-bottom: none; white-space: normal; padding-right:20px; }
#content table th { border-bottom: none; white-space: normal; vertical-align: middle; padding-right:15px }
.tablesorter-blue tbody > tr.even.selected > td,
.tablesorter-blue tbody > tr.even.selected + tr.tablesorter-childRow > td,
.tablesorter-blue tbody > tr.even.selected + tr.tablesorter-childRow + tr.tablesorter-childRow > td {
......@@ -151,7 +148,7 @@ end
<DL>
<TABLE id="loglist" class="tablesorter">
<THEAD>
<TR style=font-weight:bold;>
<TR>
<% local checkhead = true
for i,watch in ipairs(subdata) do
if watch.selected ~= "t" then
......@@ -165,12 +162,12 @@ end %>
<TH>Client IP</TH>
<TH>User ID</TH>
<TH>Size</TH>
<TH style=font-weight:bold >Sus</TH>
<TH style=font-weight:bold >Den</TH>
<TH style=font-weight:bold >Byp</TH>
<TH>Sus</TH>
<TH>Den</TH>
<TH>Byp</TH>
<TH>Score</TH>
<TH>Reason</TH>
<TH WIDTH="90%">URL</TH>
<TH>URL</TH>
<TH>Bad Words</TH>
</TR>
</THEAD>
......@@ -194,9 +191,9 @@ end %>
<TD <% if data.value.clientip.value == watch.clientip then %> style="font-weight:bold;" <% end %> ><%= html.html_escape(watch.clientip) %></TD>
<TD <% if data.value.clientuserid.value == watch.clientuserid then %> style="font-weight:bold;" <% end %> ><%= html.html_escape(watch.clientuserid) %></TD>
<TD><%= html.html_escape(watch.bytes) %></TD>
<TD WIDTH="2%"><% if watch.badyesno ~= "0" then %><IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/dodgy.png' width='13' height='13'><% end %></TD>
<TD WIDTH="2%"><% if watch.deniedyesno ~= "0" then %> <IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/denied.png' width='13' height='13'><% end %></TD>
<TD WIDTH="2%"><% if watch.bypassyesno ~= "0" then %> <IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/bypass.png' width='13' height='13'><% end %></TD>
<TD><% if watch.badyesno ~= "0" then %><IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/dodgy.png' width='13' height='13'><% end %></TD>
<TD><% if watch.deniedyesno ~= "0" then %> <IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/denied.png' width='13' height='13'><% end %></TD>
<TD><% if watch.bypassyesno ~= "0" then %> <IMG SRC='<%= html.html_escape(page_info.wwwprefix..page_info.staticdir) %>/bypass.png' width='13' height='13'><% end %></TD>
<TD><%= html.html_escape(watch.score) %></TD>
<TD<% if (watch.shortreason and watch.shortreason ~= "" and watch.reason and watch.reason ~= "") then %> title="<%= html.html_escape(watch.reason) %>"<% end %>>
<% if (watch.shortreason and watch.shortreason ~= "") then %>
......@@ -205,7 +202,7 @@ end %>
<%= html.html_escape(watch.reason) %>
<% end %>
</TD>
<TD style="word-wrap: break-word" width="500" title="<%= html.html_escape(watch.uri) %>"><% highlight_uri=html.html_escape(watch.shorturi or watch.uri)
<TD title="<%= html.html_escape(watch.uri) %>"><% highlight_uri=html.html_escape(watch.shorturi or watch.uri)
if watch.wordloc ~= nil then
if string.find(watch.wordloc, "|") then
badwords = format.string_to_table(watch.wordloc, "|")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment