Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from flask import Flask,redirect,url_for,render_template
- app = Flask(__name__)
- @app.route('/')
- def home():
- return render_template('home.html')
- @app.route('/info/')
- def info():
- file = open('info.html','r')
- content = file.read()
- file.close()
- return content
- @app.route('/lib/')
- def lib():
- return render_template('lib.html',data=['aung','win','htut'])
- @app.route('/admin/')
- def admin():
- return redirect(url_for('home'))
- if __name__ == '__main__':
- app.run()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement