# settngs.py
def cookie():
    return web.cookies()

web.template.Template.globals['cookie_office'] = cookie()


# people.py
class Login:
    def GET(self):
        cookie = web.cookies()
        return render.people.login('Login', cookie)


# login.html
$def with(title, cookie)
$:render_office.header(title)

    $if cookie == cookie_office:
        OK
    $else:
        It is wrong<br />
        cookie: $cookie.userid, $cookie.email<br />
        cookie_office: $cookie_office.userid, $cookie_office.email


OK, when I logined, and it return:
It is wrong
cookie: 2, [email protected]
cookie_office: None, None


what happend? How to fix?
thx.

-- 
新浪微博:http://t.sina.com.cn/qichangxing
腾讯微博:http://t.qq.com/qichangxing
python.cn(news, jobs) http://simple-is-better.com
办公室创意生活 http://office.simple-is-better.com/

-- 
You received this message because you are subscribed to the Google Groups 
"web.py" 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/webpy?hl=en.

Reply via email to