Fied relative path for denali

This commit is contained in:
Sergiusz Warga 2020-11-25 21:33:16 +01:00
parent 3f7b4f3a57
commit c6a8af1a06

View File

@ -17,7 +17,7 @@ def llpsi():
@app.route('/latin/llpsi/<path:pensum_id>') @app.route('/latin/llpsi/<path:pensum_id>')
def pensum(pensum_id): def pensum(pensum_id):
filename = 'app/templates/Pensa/' + pensum_id + '.html' filename = 'templates/Pensa/' + pensum_id + '.html'
with open(filename, 'r') as file: with open(filename, 'r') as file:
return render_template('LLPSI/Pensum_cloze.html', pensum_title=pensum_id.replace('_', ' '), pensum_content=file.read()) return render_template('LLPSI/Pensum_cloze.html', pensum_title=pensum_id.replace('_', ' '), pensum_content=file.read())