Here is a bit better version, just in case someone hits the action with
an empty body (i.e. a GET), the previous version would display the
error page because there was no key '__body__'

    def mirror(self):
        if
request.environ['paste.parsed_formvars'][0].has_key('__body__'):
            body =
request.environ['paste.parsed_formvars'][0]['__body__']
        else:
            body = "Request has no body" 
        return response(body)


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" 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/pylons-discuss
-~----------~----~----~----~------~----~------~--~---

Reply via email to