From 999bb888a63f22a6c7eaf242cc771b4f312ee6d7 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Mon, 12 Sep 2011 17:30:52 +0000 Subject: Changed viewweblog to a form, reworked handling of config and weblog parameters, and added deniedyesno and bypassyesno config options. --- weblog-viewweblog-html.lsp | 122 ++++++++++----------------------------------- 1 file changed, 25 insertions(+), 97 deletions(-) (limited to 'weblog-viewweblog-html.lsp') diff --git a/weblog-viewweblog-html.lsp b/weblog-viewweblog-html.lsp index 4df704e..07f6356 100644 --- a/weblog-viewweblog-html.lsp +++ b/weblog-viewweblog-html.lsp @@ -94,85 +94,18 @@ end

Search Parameters

-<% if data.errtxt then %>

<%= html.html_escape(data.errtxt) %>

<% end %> -
" method="POST"> -
Active Weblog
-
-
-
Start Time
-
-

<%= html.html_escape(data.value.starttime.value) %>

-<% if data.value.starttime.errtxt then %>

<%= html.html_escape(data.value.starttime.errtxt) %>

<% end %> -
-
User ID
-
-

<%= html.html_escape(data.value.clientuserid.value) %>

-<% if data.value.clientuserid.errtxt then %>

<%= html.html_escape(data.value.clientuserid.errtxt) %>

<% end %> -
-
Client IP
-
-

<%= html.html_escape(data.value.clientip.value) %>

-<% if data.value.clientip.errtxt then %>

<%= html.html_escape(data.value.clientip.errtxt) %>

<% end %> -
-
End Time
-
-

<%= html.html_escape(data.value.endtime.value) %>

-<% if data.value.endtime.errtxt then %>

<%= html.html_escape(data.value.endtime.errtxt) %>

<% end %> -
-
URI Contains
-
-

Retrieve records where the URI contains this word

-

<%= html.html_escape(data.value.urisearch.value) %>

-<% if data.value.urisearch.errtxt then %>

<%= html.html_escape(data.value.urisearch.errtxt) %>

<% end %> -
-
Minimum Score
-
-

Minimum score to search on

-<% if data.value.score.errtxt then %>

<%= html.html_escape(data.value.score.errtxt) %>

<% end %> -
-
Sort By
-
-
-
Show Suspect Records
-
- checked <% end %>> -

Show only URIs containing flagged words

-<% if data.value.badyesno.errtxt then %>

<%= html.html_escape(data.value.badyesno.errtxt) %>

<% end %> -
-
Show Denied URIs
-
-checked<% end %>> -<% if data.value.deniedyesno.errtxt then %>

<%= html.html_escape(data.value.deniedyesno.errtxt) %>

<% end %> -

Show only Denied URIs

-
-
Show Bypass Attempts
-
-checked <% end %>> -<% if data.value.bypassyesno.errtxt then %>

<%= html.html_escape(data.value.bypassyesno.errtxt) %>

<% end %> -

Show only Bypass attempts

-
-
Show Selected Records
-
-checked <% end %>> -<% if data.value.selected.errtxt then %>

<%= html.html_escape(data.value.selected.errtxt) %>

<% end %> -

Show only records that have been selected

-
-
-
+<% -- Display the form, but skip log, window, and focus fields +local log = data.value.log +data.value.log = nil +local window = data.value.window +data.value.window = nil +local focus = data.value.focus +data.value.focus = nil +displayform(data, nil, nil, page_info, 2) +data.value.log = log +data.value.window = window +data.value.focus = focus +%>
<% @@ -232,7 +165,7 @@ end %> style="font-weight:bold;" <% end %> ><%= html.html_escape(watch.clientip) %> style="font-weight:bold;" <% end %> ><%= html.html_escape(watch.clientuserid) %> <%= html.html_escape(watch.bytes) %> - <% if watch.badyesno == "1" then %><% end %> + <% if watch.badyesno ~= "0" then %><% end %> <% if watch.deniedyesno ~= "0" then %> <% end %> <% if watch.bypassyesno ~= "0" then %> <% end %> <%= html.html_escape(watch.score) %> @@ -269,21 +202,16 @@ end %>

No results, try adjusting search parameters

<% end %> -<% if viewlibrary.check_permission("downloadweblog") then %> -
" method="POST"> - - - - - - - - - - - - -
Download log
-
-<% end %> +<% if viewlibrary.check_permission("downloadweblog") then +data.action = "downloadweblog" +data.option = "Download" +data.value.log = nil +data.value.window = nil +data.value.focus = nil +for n,v in pairs(data.value) do + v.type = "hidden" + v.checked = nil +end +displayform(data, nil, nil, page_info, 2) +end %> -- cgit v1.2.3