Pārlūkot izejas kodu

Attempt to pass arguments correctly.

pull/24/head
Ben Kurtovic pirms 10 gadiem
vecāks
revīzija
39f3f900e2
1 mainītis faili ar 8 papildinājumiem un 3 dzēšanām
  1. +8
    -3
      app.fcgi

+ 8
- 3
app.fcgi Parādīt failu

@@ -9,6 +9,8 @@ from flask import Flask, request
from flask.ext.mako import MakoTemplates, render_template
from flup.server.fcgi import WSGIServer

from copyvios.cookies import parse_cookies

app = Flask(__name__)
MakoTemplates(app)

@@ -25,15 +27,18 @@ def write_access_log(response):

@app.route("/")
def index():
return render_template("index.mako")
cookies = parse_cookies(request.environ)
return render_template("index.mako", environ=request.environ, cookies=cookies)

@app.route("/settings")
def settings():
return render_template("settings.mako")
cookies = parse_cookies(request.environ)
return render_template("settings.mako", environ=request.environ, cookies=cookies)

@app.route("/debug")
def debug():
return render_template("debug.mako")
cookies = parse_cookies(request.environ)
return render_template("debug.mako", environ=request.environ, cookies=cookies)

if __name__ == '__main__':
WSGIServer(app).run()

Notiek ielāde…
Atcelt
Saglabāt