コード例 #1
0
ファイル: app_start.py プロジェクト: ja8685/flask_sample
from helloworld import app

if __name__ == "__name__":
    app.run(host="0.0.0.0")
コード例 #2
0
from helloworld import app

if __name__ == “__main__”:
    app.run(host=“0.0.0.0”)
コード例 #3
0
ファイル: app_start.py プロジェクト: doORdeath/DeathOfFlask
__author__ = 'Chulpyo'

from helloworld import app

if __name__ == "__main__":
    app.run(host="0.0.0.0")
コード例 #4
0
        email = form.email.data
        message = form.message.data
        new_contact_message = ContactMessage(name=name,email=email,message=message)
        db.session.add(new_contact_message)
        db.session.commit()
        flash("Thanks you '<b>{}</b>' <br> Your message has been succesfully submited".format(name))
        return redirect(url_for('index'))
    return render_template('contact.html',form=form)

@app.route('/messages/<int:post_id>')
@app.route('/messages')
#@login_required
def messages(post_id=0):    
    post_id = request.args.get('post_id') if request.args.get('post_id') else post_id
    print post_id 
    if post_id==0:        
        return render_template('messages.html',messages=ContactMessage.query.limit(10))
    else:
        return render_template('messages.html',messages=ContactMessage.query.filter_by(id=post_id).limit(10))

@app.errorhandler(404)
def page_not_found(e):
    return render_template('404.html'), 404

@app.errorhandler(500)
def server_error(e):
    return render_template('500.html'), 500

if __name__ == '__main__':
    app.run(debug=True)
コード例 #5
0
#!/env/bin/python
from helloworld import app
app.run(host = '0.0.0.0',
        port = 8080)
コード例 #6
0
# 구동 스크립트 작성
from helloworld import app

if __name__ == "__main__":
    app.run("192.168.137.2")
コード例 #7
0
ファイル: wsgi.py プロジェクト: MaxVogelFrei/linux-dz-23
from helloworld import app

if __name__ == "__main__":
    app.run()
コード例 #8
0
from helloworld import app

if __name__ == "__main__":
    app.run(host="0.0.0.0", port=80)
コード例 #9
0
ファイル: wsgi.py プロジェクト: shuo502/aliyumdockerfile
from helloworld import app as application

if __name__ == "__main__":
    application.run()
コード例 #10
0
from helloworld import app

if __name__ == "__main__":
	app.run(host="localhost", port=8080, debug=True)
コード例 #11
0
ファイル: app.py プロジェクト: agapeuni/python
from helloworld import app


if __name__ == "__main__":
    app.run(host="0.0.0.0", debug=True, port=8000)
コード例 #12
0
ファイル: app_start.py プロジェクト: Mixergi/Flask-learning
from helloworld import app

if __name__ == "__main__":
    app.run(host='0.0.0.0')
コード例 #13
0
from helloworld import app

if __name__ == "__main__":
    app.run(host="0.0.0.0", port="8080")
コード例 #14
0
ファイル: app_stary.py プロジェクト: hyomee/Python
# 구동 스크립트 작성
from helloworld import app
    
if __name__ == "__main__" :
    app.run("192.168.137.2")