Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from mysql_con import *
- from flaskext.sqlalchemy import SQLAlchemy
- from flask import Flask, request, flash, url_for, redirect, render_template, abort
- app = Flask(__name__)
- @app.route('/')
- def show_all():
- #return render_template('show_all.html', userDetails=User.query.all())
- #return render_template('index.html')
- userDetails=User.query.all()
- return userDetails
- @app.route('/index/')
- def index():
- return 'Hello World!'
- if __name__ == '__main__':
- app.run()
Add Comment
Please, Sign In to add comment