Thanks, Patrick. I will give it a try.If this works then I will have to look for some files to serve. <br><br>Ching<br><br><div><span class="gmail_quote">On 8/11/07, <b class="gmail_sendername">Patrick Collison</b> <<a href="mailto:patrick@collison.ie">
patrick@collison.ie</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On 11/08/07, Ching de la Serna <<a href="mailto:ching.dls@gmail.com">
ching.dls@gmail.com</a>> wrote:<br>> Thanks again, Boris. I am using Squeak. I suppose there is an equivalent<br>> method? I am looking at ByteArray in Squeak and I do not see a method<br>> similar in name to #contentsOfEntireBinaryFile.
<br><br>(FileStream fileNamed: 'foo') binary contents<br><br>> On 8/11/07, Boris Popov <<a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a>> wrote:<br>> ><br>> ><br>> ><br>
> > Its a standard method in visualworks to read entire file into a byte<br>> array.<br>> ><br>> > Cheers!<br>> ><br>> > -Boris<br>> > (Sent from a BlackBerry)<br>> ><br>> > ----- Original Message -----
<br>> > From:<br>> <a href="mailto:seaside-bounces@lists.squeakfoundation.org">seaside-bounces@lists.squeakfoundation.org</a><br>> <<br>> <a href="mailto:seaside-bounces@lists.squeakfoundation.org">seaside-bounces@lists.squeakfoundation.org
</a>><br>> > To: Seaside - general discussion<br>> <<a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a>><br>> > Sent: Fri Aug 10 16:50:51 2007<br>> > Subject: Re: [Seaside] How to allow downloads in Seaside?
<br>> ><br>> > Thanks again, Boris.<br>> ><br>> ><br>> > On 8/11/07, Boris Popov <<a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a>> wrote:<br>> ><br>> > Then you would just pass byte array to #downloadBytes, say
<br>> ><br>> > self<br>> > downloadBytes: 'c:\play.wav' asFilename contentsOfEntireBinaryFile<br>> ><br>> ><br>> > how would #contentsOfEntireBinaryFile be implemented? That is if I intend
<br>> to allow the download of an entire audio file that is in my server?.<br>> ><br>> ><br>> ><br>> > mime: 'audio/x-wav'<br>> > filename: 'play.wav'];
<br>> > with: 'Download WAV File!'.<br>> ><br>> > It all depends on what it is you are trying to achieve I guess.<br>> ><br>> > -Boris<br>> ><br>> > --
<br>> > +1.604.689.0322<br>> > DeepCove Labs Ltd.<br>> > 4th floor 595 Howe Street<br>> > Vancouver, Canada V6C 2T5<br>> > <a href="http://tinyurl.com/r7uw4">
http://tinyurl.com/r7uw4</a> < <a href="http://tinyurl.com/r7uw4">http://tinyurl.com/r7uw4</a>><br>> ><br>> ><br>> > <a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a><br>> >
<br>> > CONFIDENTIALITY NOTICE<br>> ><br>> > This email is intended only for the persons named in the message<br>> > header. Unless otherwise indicated, it contains information that
<br>> is<br>> > private and confidential. If you have received it in error, please<br>> > notify the sender and delete the entire message including any<br>> > attachments.<br>> >
<br>> > Thank you.<br>> > ________________________________________<br>> > From:<br>> <a href="mailto:seaside-bounces@lists.squeakfoundation.org">seaside-bounces@lists.squeakfoundation.org
</a><br>> [<br>> mailto:<a href="mailto:seaside-bounces@lists.squeakfoundation.org">seaside-bounces@lists.squeakfoundation.org</a><br>> ] On Behalf Of Ching de la Serna<br>> > Sent: Friday, August 10, 2007 4:34 PM
<br>> > To: Seaside - general discussion<br>> > Subject: Re: [Seaside] How to allow downloads in Seaside?<br>> ><br>> > Thanks Boris.<br>> > On 8/11/07, Boris Popov <
<a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a>> wrote:<br>> > Sigh, obviously anchor would need to be closed,<br>> ><br>> > html anchor<br>> > callback: [self
<br>> > downloadBytes: self asCSV<br>> ><br>> > could you show me sample code on #asCSV? I am thinking of music<br>> files to be downloaded.<br>> ><br>> > mime: 'text/csv'
<br>> > filename: 'export.csv '];<br>> > with: 'Export'.<br>> ><br>> > Cheers,<br>> ><br>> > -Boris<br>> ><br>> > --<br>
> > +1.604.689.0322<br>> > DeepCove Labs Ltd.<br>> > 4th floor 595 Howe Street<br>> > Vancouver, Canada V6C 2T5<br>> > <a href="http://tinyurl.com/r7uw4">
http://tinyurl.com/r7uw4</a><br>> ><br>> > <a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a><br>> ><br>> > CONFIDENTIALITY NOTICE<br>> ><br>> > This email is intended only for the persons named in the message
<br>> > header. Unless otherwise indicated, it contains information that<br>> is<br>> > private and confidential. If you have received it in error, please<br>> > notify the sender and delete the entire message including any
<br>> > attachments.<br>> ><br>> > Thank you.<br>> ><br>> > > -----Original Message-----<br>> ><br>> > > From:<br>> <a href="mailto:seaside-bounces@lists.squeakfoundation.org">
seaside-bounces@lists.squeakfoundation.org</a><br>> [ mailto:<a href="mailto:seaside-">seaside-</a> <mailto:<a href="mailto:seaside-">seaside-</a>><br>> > ><br>> <a href="mailto:bounces@lists.squeakfoundation.org">
bounces@lists.squeakfoundation.org</a> ] On<br>> Behalf Of Boris Popov<br>> > > Sent: Friday, August 10, 2007 3:56 PM<br>> > > To: Seaside - general discussion<br>> > > Subject: RE: [Seaside] How to allow downloads in Seaside?
<br>> > ><br>> > > I use the following extension on WAComponent,<br>> > ><br>> > > downloadBytes: bytes mime: mime filename: filename<br>> > >^self session returnResponse: (WADocumentHandler
<br>> > > document: bytes<br>> > > mimeType: mime<br>> > > fileName: filename) response<br>> > ><br>> > > which is then called from a callback, say
<br>> > ><br>> > > html anchor<br>> > > callback: [self<br>> > > downloadBytes: self asCSV<br>> > > mime: 'text/csv'<br>> > > filename: '
export.csv'].<br>> > ><br>> > > Hope this helps,<br>> > ><br>> > > Cheers!<br>> > ><br>> > > -Boris<br>> > >
<br>> > > --<br>> > > +1.604.689.0322<br>> > > DeepCove Labs Ltd.<br>> > > 4th floor 595 Howe Street<br>> > > Vancouver, Canada V6C 2T5<br>
> > > <a href="http://tinyurl.com/r7uw4">http://tinyurl.com/r7uw4</a><br>> > ><br>> > > <a href="mailto:boris@deepcovelabs.com">boris@deepcovelabs.com</a><br>> > >
<br>> > > CONFIDENTIALITY NOTICE<br>> > ><br>> > > This email is intended only for the persons named in the message<br>> > > header. Unless otherwise indicated, it contains information that
<br>> is<br>> > > private and confidential. If you have received it in error,<br>> please<br>> > > notify the sender and delete the entire message including any<br>> > > attachments.
<br>> > ><br>> > > Thank you.<br>> > ><br>> > > > -----Original Message-----<br>> > > > From:<br>> <a href="mailto:seaside-bounces@lists.squeakfoundation.org">
seaside-bounces@lists.squeakfoundation.org</a><br>> <<br>> mailto:<a href="mailto:seaside-bounces@lists.squeakfoundation.org">seaside-bounces@lists.squeakfoundation.org</a>><br>> [mailto:<a href="mailto:seaside-">
seaside-</a><br>> > > ><br>> <a href="mailto:bounces@lists.squeakfoundation.org">bounces@lists.squeakfoundation.org</a>] On<br>> Behalf Of Ching de la Serna<br>> > > > Sent: Friday, August 10, 2007 3:23 PM
<br>> > > > To:<br>> <a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org</a><br>> > > > Subject: [Seaside] How to allow downloads in Seaside?<br>
> > > ><br>> > > > Hi,<br>> > > ><br>> > > > If I were to allow downloads from my webpage, how would I go<br>> about<br>> > it?
<br>> > > > Does Seaside have a method for doing this? Many thanks.<br>> > > ><br>> > > > Ching<br>> > ><br>> > > _______________________________________________
<br>> > > Seaside mailing list<br>> > ><br>> <a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org</a><br>> > ><br>> <a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>><br>> <<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
</a><br>> ><br>> > _______________________________________________<br>> > Seaside mailing list<br>> ><br>> <a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org
</a> <<br>> mailto:<a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org</a>><br>> ><br>> <a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
</a><br>><br>> ><br>> > _______________________________________________<br>> > Seaside mailing list<br>> ><br>> <a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org
</a><br>> ><br>> <a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>><br>> <<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>> ><br>> ><br>> ><br>> ><br>> ><br>> > _______________________________________________<br>> > Seaside mailing list
<br>> > <a href="mailto:Seaside@lists.squeakfoundation.org">Seaside@lists.squeakfoundation.org</a><br>> ><br>> <a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
</a><br>><br>> ><br>> ><br>><br>><br>> _______________________________________________<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">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>><br>><br>_______________________________________________
<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">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
</a><br></blockquote></div><br>