From 03ceb994226ff571c948c36269baba2b3b2cad2a Mon Sep 17 00:00:00 2001 From: zovjsra <110753121@nccu.edu.tw> Date: Mon, 31 Jul 2023 12:25:00 +0000 Subject: [PATCH] change app.py --- app.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app.py b/app.py index 1b36d0a..a4fbc4b 100755 --- a/app.py +++ b/app.py @@ -155,6 +155,9 @@ def send_resource(path): def generaltxt_help(): return render_template('generaltxt_help.html', title="使用說明") +@app.route('/data/') +def get_data(path): + return send_from_directory('data', path) if __name__ == "__main__": app.run(debug=True, port=4980, host='0.0.0.0', threaded=False)