change this:

def login(): return dict(login=t2.login())
@t2.requires_login(next='login')
def index():
    return dict(search=t2.search
(db.t2_person,db.puppy,query=friendship),
                form=t2.create(db.puppy,onaccept=lambda
form:t2.add_access(db.puppy,form.vars.id) and db.friendship.insert
(person_id=t2.person_id,puppy_id=form.vars.id)))

into

def index():
    if t2.logged_in: t2.redirect('private_index')
    return dict()
def login(): return dict(login=t2.login())
@t2.requires_login(next='login')
def private_index():
    return dict(search=t2.search
(db.t2_person,db.puppy,query=friendship),
                form=t2.create(db.puppy,onaccept=lambda
form:t2.add_access(db.puppy,form.vars.id) and db.friendship.insert
(person_id=t2.person_id,puppy_id=form.vars.id)))

Massimo

On Nov 13, 2:52 am, ed <[EMAIL PROTECTED]> wrote:
> Hi,
> The default display of Puppy app is the login display. How can i
> change the default display without changing "login" function. I would
> like to display some text below the menu ("LOGIN" "REGISTER") once the
> app is loaded and display the login screen only after "LOGIN" is
> clicked in the menu bar. I've checked the source in the controllers
> and view and also in the plugin t2 but did not find any or was too
> complex for me. Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to