From 5b0caf46c815a61bb2e6f02334264f9afc8a66f6 Mon Sep 17 00:00:00 2001 From: clyhtsuriva Date: Thu, 7 May 2020 11:52:55 +0200 Subject: ajout fenetre flottante index.py --- www/html/destination.py | 5 +++++ www/html/index.py | 8 ++++++++ www/html/style.css | 12 +++++++++++- 3 files changed, 24 insertions(+), 1 deletion(-) diff --git a/www/html/destination.py b/www/html/destination.py index cc8713a..4d37c22 100755 --- a/www/html/destination.py +++ b/www/html/destination.py @@ -26,9 +26,13 @@ def index(req): conn=connexionBD() cur=conn.cursor() sql="select * from paquet where ip_destination='{}';".format(ip) + sql_count="select count(*) from paquet where ip_destination='{}';".format(ip) cur.execute(sql) conn.commit() data=cur.fetchall() + cur.execute(sql_count) + conn.commit() + rec=cur.fetchone() conn.close() #sql part @@ -46,6 +50,7 @@ def index(req): #write the html page req.write(baseHTML("Destination","""

IP Destination : """ + ip + """

+

Nombre de paquets en destination de """+ ip + """ : """+ str(rec[0])+ """

""" diff --git a/www/html/index.py b/www/html/index.py index 958c5be..d483458 100755 --- a/www/html/index.py +++ b/www/html/index.py @@ -32,6 +32,8 @@ def index(req): #write the html page req.write(baseHTML("ATS-Project","""

ATS-Project

+
+Pour voir le nombre de paquets en destination d'une adresse IP, cliquez sur cette derniere dans le tableau.
OK
Filtre
@@ -43,4 +45,10 @@ def index(req):
HeureProtocoleIP SourceIP DestinationPort SourcePort Destination
+ """)) diff --git a/www/html/style.css b/www/html/style.css index 45ce811..a826da5 100755 --- a/www/html/style.css +++ b/www/html/style.css @@ -19,7 +19,7 @@ a { text-decoration: none; } - a:hover { +a:hover { color: red; } @@ -27,3 +27,13 @@ table,th,td { border: 2px solid red; text-align: center; } + +#tip { + color: #6666ff; + position: fixed; + bottom: 10px; + right: 50px; + border: solid #6666ff; + padding:10px; + background-color: black; +} -- cgit v1.2.3