Web2py controllers with parameters?

Posted by nickfranceschina on Stack Overflow See other posts from Stack Overflow or by nickfranceschina
Published on 2010-06-09T06:12:10Z Indexed on 2010/06/09 6:12 UTC
Read the original article Hit count: 277

Filed under:
|

I am building an app using Web2py framework... I don't want to have to use the request object to get all of the querystring parameters, instead I'd like to build my controller with named parameters and have the router unpack the querystring (or form data) dictionary into the named parameters and call my controller.

so instead of a controller method of

create_user():

where I would use the global request() object and look through the vars list... I would prefer instead to have

create_user(first_name, last_name, email):

like I see in other MVC platforms.

is this possible in Web2py already? or is there a plugin for it? or do I need to add that myself?

© Stack Overflow or respective owner

Related posts about python

Related posts about web2py