diff --git a/app.py b/app.py index bf5dc42..7c4ec81 100644 --- a/app.py +++ b/app.py @@ -5,8 +5,15 @@ import pages app = Flask(__name__) @app.route('/') +@app.route('/home') +@app.route('/home/') def main(): return pages.main() +@app.errorhandler(404) +def error(e): + return pages.error() + + if __name__=="__main__": app.run(debug=True) diff --git a/pages.py b/pages.py index 35b94b5..af35d37 100644 --- a/pages.py +++ b/pages.py @@ -4,4 +4,7 @@ import definitions as lib # Fonctions qui seront associées à des URLs def main(): - return render_template("main.html") + return render_template("index.html") + +def error(): + return render_template("error.html") diff --git a/site.db b/site.db new file mode 100644 index 0000000..f300121 Binary files /dev/null and b/site.db differ diff --git a/templates/bateau_temp.html b/templates/bateau_temp.html new file mode 100644 index 0000000..78e119c --- /dev/null +++ b/templates/bateau_temp.html @@ -0,0 +1,41 @@ + + + + + {{nom}} + + + +

{{nom}}}

+ + + + + + + + + + + + + + + + + + + + + + + + + +
Nom{{NomBateau}}
Constructeur{{nom}}
Dimensions{{Dimensions}}
Installation{{Date}}
Condamnation{{Date}}
Origine{{ville}}
+

+ {{HistoireBateau}} +

+ + + \ No newline at end of file diff --git a/templates/error.html b/templates/error.html new file mode 100644 index 0000000..f324eed --- /dev/null +++ b/templates/error.html @@ -0,0 +1,11 @@ + + + + + + +

Erreur !

+

Retour à la page d'accueil

+ + + diff --git a/templates/main.html b/templates/main.html deleted file mode 100644 index 9768fc8..0000000 --- a/templates/main.html +++ /dev/null @@ -1,24 +0,0 @@ - - - - Sauveteurs du dunkerquois - - - -
-
- -
-
-
- - -
-
-
- -
-
-