[Seaside] Making a download page
ricardo.jacas at gmail.com
Sun Mar 20 19:08:33 UTC 2011
no, but i'm not trying anymore, thanks very much for the advice anyway
2011/3/20 AA <aa at serendip.demon.co.uk>
> Hi Avi, Ricardo
> I found my error! I'd set the file download directory to be in my home
> directory: '/home/me/downloads'. But, of course, this absolute path isn't
> recognised as a valid URL by nginx, so (duh!) that's why it wouldn't work.
> After moving '/downloads' to the root directory (and changing the
> permissions), it works fine.
> I've also found it necessary to use 'attachmentWithFileName:', otherwise
> the web server assumes the content-disposition to be 'inline' rather than
> 'attached', and displays the file instead of saving it.
> Avi, thanks for all your help! Ricardo, have you managed to get your
> downloads working yet?
> On Sun, 13 Mar 2011 10:05:40 +0200
> Avi Shefi <avishefi at gmail.com> wrote:
> > Amir,
> > Your code is fine, and works OK. The only thing that's wrong is that it
> > contentType:attachementWithFileName , whereas X-Accel-Redirect doesn't
> > require these headers. Using these headers will confuse browsers into
> > thinking that you're actually trying to download a file (without
> > redirection). This is why you get a file with 0 bytes - there's no file
> > contents in the transport.
> > You should use only contentType and X-Accel-Redirect to specify your
> seaside mailing list
> seaside at lists.squeakfoundation.org
lets reign all together
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the seaside