Skip to content

Commit

Permalink
Simple index page
Browse files Browse the repository at this point in the history
  • Loading branch information
mpessas committed Dec 29, 2010
1 parent 5958362 commit 098cd1c
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions notify.py
@@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-

from bottle import route, run, Bottle
from google.appengine.api import users

myapp = Bottle()

@myapp.route('/')
@myapp.route('/index.html')
def index():
return "<a href='/login'>Log in</a>"

@myapp.route('/login')
def login():
user = users.get_current_user()
if user:
return "<p>Hi %s</p>" % user.nickname()
else:
return "<p>Hi, anonymous</p>"

0 comments on commit 098cd1c

Please sign in to comment.