[Seaside] Using nginx file upload module
johan at inceptive.be
Thu Jun 16 07:21:47 UTC 2011
After writing my last response, I got the picture...
Because Seaside ignores whatever comes in the path after the application name, the request will be processed by the seaside app anyway. This is what I failed to see.
In our attempts, we _replaced_ the action url on the form by something like '/fileupload?_s=...&k=...'.
Instead, you merely _append_ to the action url such that it has the form: '/<app>/fileupload?_s=...&k=...'
That last url will be correctly handled as an incoming request for <app> by seaside, ignoring whatever comes after in the path.
Great 'aha!' moment ;-) Thanks!
On 16 Jun 2011, at 08:57, Johan Brichau wrote:
> On 15 Jun 2011, at 22:53, Nick Ager wrote:
> Okay, so it's all a bit trickier than I thought.
> I was trying to rewrite the request to '/upload' after nginx has processed the file, such that the normal callback invocation of the seaside application can do its work with the request (except that a hidden field is required in this case).
> Unfortunately, that does not seem to work and you thus need to handle the '/upload' request in the seaside backend as well.
> I'm still not entirely convinced that a rewrite of the request in nginx after the file processing should not work though ;-) I will give it another try.
> But I'm looking forward to reading your write-up too!
> thanks again
> seaside mailing list
> seaside at lists.squeakfoundation.org
More information about the seaside