mirror of
https://github.com/sigmasternchen/Diary
synced 2025-03-15 07:08:56 +00:00
Added basic HTML page
This commit is contained in:
parent
60b5d38b05
commit
e9323c4859
2 changed files with 19 additions and 1 deletions
10
server
10
server
|
@ -1,10 +1,18 @@
|
|||
#!/usr/bin/env python2.7
|
||||
|
||||
import os
|
||||
from flask import Flask
|
||||
from flask import Flask,render_template,abort,redirect,url_for
|
||||
|
||||
app=Flask(__name__)
|
||||
|
||||
@app.errorhandler(404)
|
||||
def err404(err):
|
||||
return redirect(url_for('index'))
|
||||
|
||||
@app.route('/')
|
||||
def index():
|
||||
return render_template('index.html')
|
||||
|
||||
if __name__=='__main__':
|
||||
app.debug=True
|
||||
app.secret_key=os.urandom(64)
|
||||
|
|
10
templates/index.html
Normal file
10
templates/index.html
Normal file
|
@ -0,0 +1,10 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Diary</title>
|
||||
</head>
|
||||
<body>
|
||||
No content yet!
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in a new issue