aboutsummaryrefslogtreecommitdiff
path: root/web/website/fonctions.py
diff options
context:
space:
mode:
authorcly <clyhtsuriva@gmail.com>2020-03-22 13:09:02 +0100
committercly <clyhtsuriva@gmail.com>2020-03-22 13:09:02 +0100
commit126f0be550539ba2dda2bb8ae508bd9e67f0973d (patch)
tree6560987176c9a1e84555bdf26d50f9d31ccca48c /web/website/fonctions.py
parent85534f576e13cbb05d48f2c8210c917a38085c3a (diff)
howto psql
Diffstat (limited to 'web/website/fonctions.py')
-rw-r--r--web/website/fonctions.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/web/website/fonctions.py b/web/website/fonctions.py
index c968351..c1566af 100644
--- a/web/website/fonctions.py
+++ b/web/website/fonctions.py
@@ -1,5 +1,6 @@
#!/usr/bin/python3
# -*- coding: utf-8 -*-
+import psycopg2
def baseHTML(title,body):
content=("""<!DOCTYPE html>
@@ -14,3 +15,9 @@ def baseHTML(title,body):
""")
return content
+
+
+def connexionBD():
+ connexion=psycopg2.connect ("host='localhost' dbname='atsdb' user='atsuser' password='123456'")
+ return connexion
+