diff options
Diffstat (limited to 'health-networkstats-html.lsp')
-rw-r--r-- | health-networkstats-html.lsp | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/health-networkstats-html.lsp b/health-networkstats-html.lsp index fcc2476..3963773 100644 --- a/health-networkstats-html.lsp +++ b/health-networkstats-html.lsp @@ -141,34 +141,36 @@ }); </script> -<H1>Network Statistics</H1> -<DL> +<h1>Network Statistics</h1> Network traffic in bytes/second <div id="chart" style="width:680px; height:300px;"></div> -<DT>Display Options</DT> -<DD><TABLE style="width:auto;"> -<TR><TD><B>Interface</B></TD><TD><B>IP Address</B></TD><TD colspan="2" style="text-align:center;"><B>RX</B></TD><TD colspan="2" style="text-align:center;"><B>TX</B></TD></TR> +<div class='item'><p class='left'>Display Options</p> +<div class='right'> +<table class="tablesorter"><thead> +<tr><th>Interface</th><th>IP Address</th><th colspan="2">RX</th><th colspan="2">TX</th></tr> +</thead><tbody> <% for i,intf in ipairs(interfaces) do %> - <TR><TD><%= html.html_escape(intf) %></TD><TD><%= html.html_escape(view.value[intf].ipaddr) %></TD> - <TD><INPUT type="checkbox" name="<%= html.html_escape(intf) %>RX" checked="checked"></TD> - <TD><DIV style="border:1px solid #ccc;padding:1px"><DIV style="width:14px;height:10px;background-color:<%= rgb[i][1] %>;overflow:hidden"></DIV></DIV></TD> - <TD><INPUT type="checkbox" name=<%= html.html_escape(intf) %>TX checked="checked"></TD> - <TD><DIV style="border:1px solid #ccc;padding:1px"><DIV style="width:14px;height:10px;background-color:<%= rgb[i][2] %>;overflow:hidden"></DIV></DIV></TD></TR> + <tr><td><%= html.html_escape(intf) %></td><td><%= html.html_escape(view.value[intf].ipaddr) %></td> + <td><input type="checkbox" name="<%= html.html_escape(intf) %>RX" checked="checked"></td> + <td><div style="width:14px;height:10px;border:1px solid #ccc;padding:1px"><div style="width:14px;height:10px;background-color:<%= rgb[i][1] %>;overflow:hidden"></div></div></td> + <td><input type="checkbox" name=<%= html.html_escape(intf) %>TX checked="checked"></td> + <td><div style="width:14px;height:10px;border:1px solid #ccc;padding:1px"><div style="width:14px;height:10px;background-color:<%= rgb[i][2] %>;overflow:hidden"></div></div></td></tr> <% end %> -</TABLE></DD> -<DT>Start / Stop</DT> -<DD> -<input CLASS="submit" TYPE="button" ID="Start" VALUE="Start"> -<input CLASS="submit" TYPE="button" ID="Stop" VALUE="Stop"> -</DD> -</DL> +</tbody></table> +</div></div><!-- end .item --> + +<div class='item'><p class='left'>Start / Stop</p> +<div class='right'> +<input class="submit" type="button" id="Start" value="Start"> +<input class="submit" type="button" id="Stop" value="Stop"> +</div></div><!-- end .item --> <% --[[ -- display table of colors %> -<TABLE style="width:auto;"> +<table style="width:auto;"> <% for i=1,#rgb do %> -<TR><TD><DIV style="border:1px solid #ccc;padding:1px"><DIV style="width:14px;height:10px;background-color:<%= rgb[i][1] %>;overflow:hidden"></DIV></DIV></TD> -<TD><DIV style="border:1px solid #ccc;padding:1px"><DIV style="width:14px;height:10px;background-color:<%= rgb[i][2] %>;overflow:hidden"></DIV></DIV></TD></TR> +<tr><td><div style="border:1px solid #ccc;padding:1px"><div style="width:14px;height:10px;background-color:<%= rgb[i][1] %>;overflow:hidden"></div></div></td> +<td><div style="border:1px solid #ccc;padding:1px"><div style="width:14px;height:10px;background-color:<%= rgb[i][2] %>;overflow:hidden"></div></div></td></tr> <% end %> -</TABLE> +</table> <% --]] %> |