def profile(self): if not request.environ.get('REMOTE_USER', False): abort(401) c.user = h.get_user(request.environ['REMOTE_USER']) return render('account/profile.html')
def signout(self): ''' Action to sign the user out. The actual signout happens when the middleware captures the request, so this function just displays a confirmation pageFor ``cookie`` authentication this function's routing must be added to the ``authkit.cookie.signoutpath`` directive. ''' return render('account/signedout.html')
def signin(self): identity = request.environ.get('repoze.who.identity') if identity is not None: came_from = request.params.get('came_from', '') if request.environ.get('HTTP_REFERER', '').startswith(came_from)\ or not came_from: redirect('/account/profile') if came_from: redirect(str(came_from)) c.failed = request.url == request.environ.get('HTTP_REFERER','') return render('/account/signin.html')
def map(self): return render('map.html')
def index(self): return render('index.html')
def result(self): ''' Target of redirect from submit. Simply returns a "Registration Successful!" page ''' return render('account/success.html')
def register(self): '''Renders the registration form.''' return render('account/register.html')