On Thu, Mar 10, 2011 at 01:07:32PM -0800, Seth wrote:
>
> Are those of us not returning "real" Response objects stuck with building 
> our cookie strings manually, or am I missing something here?

I think you should be able to use a sacrificial WebOb Response object
to construct the cookies for you.

Here's an untested example of what I mean:

    import webob       

    res = webob.Response()
    res.set_cookie(cookie_name, cookie_value,
                   path='/', max_age=max_age, httponly=True)
    request.response_headerlist =  [
        ('Set-Cookie', _)
        for _ in res.headers.getall('Set-Cookie') ]

Jeff

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-devel" group.
To post to this group, send email to pylons-devel@googlegroups.com.
To unsubscribe from this group, send email to 
pylons-devel+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/pylons-devel?hl=en.

Reply via email to