summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2013-05-22 12:05:14 +0200
committerAlexander Sulfrian <alexander@sulfrian.net>2013-05-22 12:09:10 +0200
commite6ceac59f7304f4bc83780462be9a70be6661908 (patch)
tree53506117a2a9ba694dd989626eb806ac4745ca08 /templates
parent379ea7d5bc1c752adc91d2abf4f85a1fb23576a5 (diff)
downloadwww-e6ceac59f7304f4bc83780462be9a70be6661908.tar.gz
www-e6ceac59f7304f4bc83780462be9a70be6661908.tar.bz2
www-e6ceac59f7304f4bc83780462be9a70be6661908.zip
host: ports are now sortable
Diffstat (limited to 'templates')
-rw-r--r--templates/host.html16
-rw-r--r--templates/layout.html1
2 files changed, 15 insertions, 2 deletions
diff --git a/templates/host.html b/templates/host.html
index 074867d..df34ab2 100644
--- a/templates/host.html
+++ b/templates/host.html
@@ -43,10 +43,13 @@
</div>
<div class="tab-pane" id="ports">
- <table class="table table-stripped table-hover">
+ <table id="portstable" class="table table-striped table-hover tablesorter">
<thead>
<tr>
- <th>Port</th><th>IP</th><th>Process</th><th>Protocol</th>
+ <th>Port</th>
+ <th>IP</th>
+ <th>Process</th>
+ <th>Protocol</th>
</tr>
</thead>
<tbody>
@@ -64,4 +67,13 @@
</table>
</div>
</div>
+
+<script>
+<!--
+ $(function() {
+ // force column "IP" to text (ips sometimes are parsed as digits)
+ $("table#portstable").tablesorter({ headers: { 1: { sorter:'text' } } });
+ });
+//-->
+</script>
{% endblock %}
diff --git a/templates/layout.html b/templates/layout.html
index e7d9014..2acf478 100644
--- a/templates/layout.html
+++ b/templates/layout.html
@@ -10,6 +10,7 @@
<link rel="stylesheet" type="text/css" media="screen" href="css/custom.css" />
<script src="js/jquery-2.0.0.min.js"></script>
+ <script src="js/jquery.tablesorter.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/list.min.js"></script>
</head>