Index: applications/mobileblur/controllers/default.py ================================================================== --- applications/mobileblur/controllers/default.py +++ applications/mobileblur/controllers/default.py @@ -27,5 +27,12 @@ redirect(URL("index")) except Exception as ex: login_form.insert(-1, ex.message) return dict(login_form=login_form) + + +def logout(): + response.cookies["nb_cookie"] = "" + response.cookies["nb_cookie"]["expires"] = -10 + response.cookies["nb_cookie"]["path"] = "/" + redirect(URL("index")) Index: applications/mobileblur/views/layout.html ================================================================== --- applications/mobileblur/views/layout.html +++ applications/mobileblur/views/layout.html @@ -102,10 +102,11 @@ {{block left_sidebar}}Content Left Sidebar{{end}} {{pass}} + Log out