示例#1
0
def get_photo(local_path):
    if '..' in local_path:
        abort(403)

    dest = os.path.join(config['LOCAL_SERVER_LOCATION'], local_path)
    if not os.path.exists(dest):
        abort(404)

    return app.send_static_file(dest)
示例#2
0
def favicon():
    return app.send_static_file("favicon.ico")
示例#3
0
def static_content(filename):
    return app.send_static_file(filename)