aboutsummaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
authorClyhtsuriva <clyhtsuriva@gmail.com>2020-05-08 19:22:32 +0200
committerClyhtsuriva <clyhtsuriva@gmail.com>2020-05-08 19:22:32 +0200
commit8b57e76f64cf5de3d0a810019a7fcff03d876544 (patch)
tree5f8a55964dddb42f35d7031dd33315cd1f21fc55 /www
parenta712e0aec4a30b69fcedae4619aee320dd3d93b4 (diff)
Ajout page analyse
Ajout d'une page analyse.py quasi vierge et de l'entrée "Analyse" dans la balise nav de fonctions.py.
Diffstat (limited to 'www')
-rw-r--r--www/html/analyse.py27
-rwxr-xr-xwww/html/fonctions.py1
2 files changed, 28 insertions, 0 deletions
diff --git a/www/html/analyse.py b/www/html/analyse.py
new file mode 100644
index 0000000..de55e47
--- /dev/null
+++ b/www/html/analyse.py
@@ -0,0 +1,27 @@
+#!/usr/bin/python3
+# -*- coding: utf-8 -*-
+
+import mod_python
+from fonctions import baseHTML, connexionBD, lien
+
+def index(req):
+ req.content_type="text/html"
+ content=str()
+'''
+#sql part
+ conn=connexionBD()
+ cur=conn.cursor()
+ sql="select * from paquet;"
+ cur.execute(sql)
+ conn.commit()
+ data=cur.fetchall()
+ conn.close()
+#sql part
+'''
+
+#write the html page
+ req.write(baseHTML("ATS-Project","""
+<center><h1>Analyse</h1></center>
+"""
++ content
+))
diff --git a/www/html/fonctions.py b/www/html/fonctions.py
index b9efce1..a8d4c8b 100755
--- a/www/html/fonctions.py
+++ b/www/html/fonctions.py
@@ -15,6 +15,7 @@ def baseHTML(title,body):
<a href="/">Index</a>
<a href="/filtrage.py">Filtrage</a>
<a href="/syntaxe.py">Syntaxe</a>
+ <a href="/analyse.py">Analyse</a>
</nav>
"""+ body +"""</body>
</html>