Re: [Zope3-Users] Accessing raw post data

2010-08-27 Thread Adam GROSZER
Hello Edoardo, Just make sure you test your app with retries. Friday, August 27, 2010, 9:50:31 AM, you wrote: ES> Hi guys, ES> I just found that I can get the body of the POST request through: ES> request.bodyStream.getCacheStream() ES> Thanks for your contribution ES> Edoardo ES> On Aug 24

Re: [Zope3-Users] Accessing raw post data

2010-08-27 Thread Edoardo Serra
Hi guys, I just found that I can get the body of the POST request through: request.bodyStream.getCacheStream() Thanks for your contribution Edoardo On Aug 24, 2010, at 10:30 PM, Edoardo Serra wrote: > Hi Adam, > thanks for your help, z3c.jsonrpc did what I was looking for. > > I now ne

Re: [Zope3-Users] Accessing raw post data

2010-08-25 Thread Jim Washington
to Zope3-Users list after updating subscription email address... On Wed, 2010-08-25 at 13:06 +0200, Adam GROSZER wrote: > Hello Edoardo, > > I think the simplest would be to make the upload a > multipart/form-data, with some headers added if you can. > Worst case putting the necessary text manual

Re: [Zope3-Users] Accessing raw post data

2010-08-25 Thread Adam GROSZER
Hello Edoardo, I think the simplest would be to make the upload a multipart/form-data, with some headers added if you can. Worst case putting the necessary text manually around the binary? Then it's a usual POST request what's easily parsed by zope. Otherwise it could be really nasty. Tuesday, Au

Re: [Zope3-Users] Accessing raw post data

2010-08-24 Thread Edoardo Serra
Hi Adam, thanks for your help, z3c.jsonrpc did what I was looking for. I now need to access the raw post data because I also have to deal with non JSON content. I'm handling a file upload through javascript and the file content is passed in the request body. Do you know how to handle th

Re: [Zope3-Users] Accessing raw post data

2010-07-22 Thread Adam GROSZER
Hello Edoardo, You might be interested in z3c.json, z3c.jsonrpc. Especially z3c.jsonrpc, that should handle such requests with ease. Wednesday, July 21, 2010, 7:33:29 PM, you wrote: ES> Hi guys, ES> I need to access the body of an HTTP POST request. ES> The request has content type of '

[Zope3-Users] Accessing raw post data

2010-07-21 Thread Edoardo Serra
Hi guys, I need to access the body of an HTTP POST request. The request has content type of 'application/json' and the body is a JSON-encoded string. I tried to access the bodyStream attribute of the BrowserRequest object but it always returns an empty string. I used a network analyzer