El Tue, 20 May 2014 15:27:29 -0700 (PDT)
Cory <[email protected]> escribió:

> Hi,
> I am trying to access the contents of a post request made to a url on
> my website. 
> To test this I have been trying to send post requests to a url on my 
> website to see I if am able to get the data from the post.
> Does anyone know how I can access the post data? am I accessing it
> correctly by using "request.vars"?  
> thanks!  
> 
> def post_sender():
>     requests.post(url,data)
> 
> def post_receiver():
>     if request.vars:
>        do stuff with data
> 
> 
> 

something like:

def post_sender():
        redirect(URL('youController','post_receiver',
        vars=dict(myvar="someValue")))

        return dict()

def post_receiver():
        if request.vars.myvar:
                do stuff with data

that's pretty much it.

Marco.

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to