mirror of
https://github.com/tiyn/beaker-blog.git
synced 2026-02-22 12:54:48 +01:00
standalone added
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from flask import Flask, flash, make_response, render_template, request, redirect
|
||||
from flask import Flask, flash, make_response, render_template, request, redirect, abort
|
||||
|
||||
import content as con_gen
|
||||
|
||||
@@ -24,6 +24,13 @@ def blog_archive():
|
||||
content = con_gen.gen_arch_string()
|
||||
return render_template('archive.html', title='Blog Archive', content_string=content)
|
||||
|
||||
@app.route('/entry/<path>')
|
||||
def entry(path):
|
||||
content = con_gen.gen_stand_string(path)
|
||||
if content != '':
|
||||
return render_template('standalone.html', title='Blog Entry', content_string=content)
|
||||
abort(404)
|
||||
|
||||
|
||||
@app.route('/feed.xml')
|
||||
@app.route('/rss.xml')
|
||||
|
||||
Reference in New Issue
Block a user