<div dir="ltr"><font color="#330033"><font size="2"><font face="tahoma,sans-serif">Amir,<br>The headers look fine. I&#39;m interested in your code, specifically from where you get a MultiByteFileStream.<br>Could you elaborate please? maybe supply your code?<br>
<br><br>Cheers,<br>Avi.<br></font></font></font><br><div style="margin: 0pt;" name="sig_d41d8cd98f"></div><div class="gmail_quote">On Fri, Mar 11, 2011 at 10:19 AM, AA <span dir="ltr">&lt;<a href="mailto:aa@serendip.demon.co.uk">aa@serendip.demon.co.uk</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">Hi Avi<br>
<br>
WAFileLibrary mimetypeFor: is a better method, thanks!  WAAnchorTag &gt;&gt; document:mimeType:fileName: doesn&#39;t seem to work with MultiByteFileStream; I get errors.<br>
<br>
In any case, with the current code, the response headers appear to be correct, so it probably indicates a problem with nginx.  Just for reference, this is what I get from &#39;Transcript show: response headers&#39;:<br>
<br>
        a WAHeaderFields(&#39;Content-Type&#39;-&gt;&#39;image/png&#39; &#39;Content-Disposition&#39;-&gt;&#39;attachment; filename=&quot;/downloads/test.png&quot;&#39; &#39;X-Accel-Redirect&#39;-&gt;&#39;/downloads/test.png&#39;)<br>

<br>
I&#39;ll keep digging, just want to verify that I&#39;m doing things properly on the Seaside end!<br>
<br>
Thanks,<br>
<br>
Amir<br>
<br>
<br>
<br>
On Thu, 10 Mar 2011 21:53:13 +0200<br>
<div class="im">Avi Shefi &lt;<a href="mailto:avishefi@gmail.com">avishefi@gmail.com</a>&gt; wrote:<br>
<br>
</div><div class="im">&gt; As for the detection of mime types, why not use: WAFileLibrary mimetypeFor:<br>
&gt; (aFilename copyAfterLast: $.)<br>
&gt; The bug that MIMEDocument class&gt;&gt;#forURIReturnSingleMimeTypeOrDefault:<br>
&gt; doesn&#39;t exist is associated with Pharo, not with Seaside (the class is in a<br>
&gt; Pharo package named Network-MIME). You&#39;re invited to file a bug in the Pharo<br>
&gt; issues list: <a href="http://code.google.com/p/pharo/issues/list" target="_blank">http://code.google.com/p/pharo/issues/list</a><br>
&gt;<br>
&gt; As for the MultiByteFileStream - I looked around and I *think* WAAnchorTag<br>
&gt; can accept a MultiByteFileStream, which is later on converted to a<br>
&gt; WAMimeDocument. Have you given this a try?<br>
&gt; In general, if you somehow managed to get a MultiByteFileStream, it means<br>
&gt; that you should also hold the path to that file. So why not pass this path<br>
&gt; to the nginx-related X-Sendfile headers?<br>
</div><div><div></div><div class="h5">_______________________________________________<br>
seaside mailing list<br>
<a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
</div></div></blockquote></div><br></div>