#871: params for get and post behave differently
--------------------------------+-------------------------------------------
Reporter: [EMAIL PROTECTED] | Owner: anonymous
Type: defect | Status: new
Priority: normal | Milestone:
Component: TurboGears | Version: 0.9a5
Severity: normal | Keywords:
--------------------------------+-------------------------------------------
GET and POST data are not available to the exposed method using the same
ruleset.
I'm not sure if this is a cherrypy issue or a tg issue , as this seems to
affect items in cherrypy.request.params as well
Instead of writing about it, let me just illustrate
given:
{{{
class Root(controllers.RootController):
test = TestController()
class TestController(controllers.Controller):
@expose()
def index(self, **kw):
return dict( kw )
}}}
case:
{{{
GET /test/?a=b
}}}
yields
{{{
kw = { 'a':'b' }
}}}
case:
{{{
GET /test?a=b
}}}
yields
{{{
kw = { 'a':'b' }
}}}
case
{{{
POST /test
c = d
}}}
yields
{{{
kw = {}
}}}
case
{{{
POST /test/
c = d
}}}
yields
{{{
kw = {'c':'d'}
}}}
case
{{{
POST /test?a=b
c = d
}}}
yields
{{{
kw = {'a':'b'}
}}}
case
{{{
POST /test/?a=b
c = d
}}}
yields
{{{
kw = {'a':'b','c':'d'}
}}}
--
Ticket URL: <http://trac.turbogears.org/turbogears/ticket/871>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Tickets" 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/turbogears-tickets
-~----------~----~----~----~------~----~------~--~---