diff --git a/htroot/ViewLog_p.java b/htroot/ViewLog_p.java index f07b70eb1..dbbd79032 100644 --- a/htroot/ViewLog_p.java +++ b/htroot/ViewLog_p.java @@ -45,6 +45,7 @@ public class ViewLog_p { final serverObjects prop = new serverObjects(); String[] log = new String[0]; boolean reversed = false; + boolean json = false; int maxlines = 400, lines = 200; String filter = ".*.*"; @@ -58,6 +59,9 @@ public class ViewLog_p { if(post.containsKey("filter")){ filter = post.get("filter"); } + if(post.containsKey("json")){ + json = true; + } } @@ -104,10 +108,10 @@ public class ViewLog_p { else if (nextLogLine.startsWith("W ")) level = 3; else if (nextLogLine.startsWith("S ")) level = 2; else if (nextLogLine.startsWith("I ")) level = 1; - else if (nextLogLine.startsWith("D ")) level = 0; - + else if (nextLogLine.startsWith("D ")) level = 0; prop.put("log_" + lc + "_level", level); - prop.putHTML("log_" + lc + "_line", nextLogLine); + if (json) prop.putJSON("log_" + lc + "_line", nextLogLine); + else prop.put("log_" + lc + "_line", nextLogLine); lc++; } prop.put("log", lc); diff --git a/htroot/ViewLog_p.json b/htroot/ViewLog_p.json new file mode 100644 index 000000000..cad3282c2 --- /dev/null +++ b/htroot/ViewLog_p.json @@ -0,0 +1,13 @@ +{ + "clientname": "#[clientname]#", + "line": "#[lines]#", + "maxlines": "#[maxlines]#", + "reverse": "#(reverseChecked)#false::true#(/reverseChecked)#", + "filter": "#[filter]#", + "loglines": [ + #{log}#{ + "loglevel": "#(level)#Debug::Info::System::Warning::Error#(/level)#", + "logline": "#[line]#" + },#{/log}#{loglevel: "", logline: ""} + ] +} \ No newline at end of file diff --git a/htroot/yacy/ui/index.html b/htroot/yacy/ui/index.html index abe6e3318..db07b618e 100644 --- a/htroot/yacy/ui/index.html +++ b/htroot/yacy/ui/index.html @@ -12,15 +12,14 @@ - + - - - + + @@ -52,6 +51,7 @@ return (this.match(str+"$")==str) } $(function() { + theme = "start"; qtag = ""; flex = {}; bmk_tab = 2; @@ -157,7 +157,7 @@ /* Select Theme Dialog */ $("#theme_select").dialog({ autoOpen: false, - height: 220, + height: 270, width: 275, position: ['top',200], modal: true, @@ -172,7 +172,7 @@ } }); $("#theme").change(function() { - var src = "css/themes/" + $("#theme").getValue() +"/images/theme.png"; + var src = "img/themes/"+$("#theme").getValue()+".png"; $("#theme_preview").attr("src", src).trigger("update"); }); /* Initialize Edit Tags Dialog */ @@ -310,7 +310,8 @@
This dialog lets you select an alternate theme/skin for YaCy-UI.