This is described in the book

def test_session():
    if not session.c: session.c=0
    session.c+=1
    return dict(counter=session.c)

def test_cookie():
    import time
    if request.cookies.has_key('mycookie'):
        return dict(mycookie=request.cookies['mycookie'].value)
    else:
        response.cookies['mycookie']="saved at "+time.ctime()
        return dict(mressage='no cookie, storing it now')

There is not really much more than this. web2py takes care of
evreything else.

On Mar 3, 2:53 am, Jason Brower <[email protected]> wrote:
> I am learning about ASP.net handling cookies and sessions.  Could
> someone point me to some documentation to both?  I can do sessions right
> now just fine because of the auth tools, but the cookies are interesting
> and I have no clue how they work.
> Thanks in advance:)
> Regards,
> Jason Brower
--~--~---------~--~----~------------~-------~--~----~
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