Thanks for the suggestion. Based on your suggestion, I decided to implement a generic component/service/asset combination that I could use for handling any of these "click to download" situations by providing an inputstream to a "DataStreamLink" component. This component would make use of a DataStreamService, etc.. and I would then create a FileStreamLink that makes use of the DataStreamLink..
The issue of I have discovered is that if I wish to pass the InputStream as a parameter to my DataStreamLink, then pass that to the service through a serviceLink.. the inputstream will be serialized (I am pretty certain it isn't serializable so this was my first clue I am on the wrong track).. Any suggestions? Luke Galea Software Development BlueCat Networks 905-762-5225 -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: September 25, 2002 6:39 PM To: Luke Galea Cc: Tapestry Developer Subject: Re: [Tapestry-developer] Implementing a download button The normal services are about pages. This is not a page. You should create a new service (somewhat like creating a new servlet, but much easier). See how the Chart page of the Workbench works. It creates a new type of asset for representing a Chart that links to a chart service that builds the URL. -- [EMAIL PROTECTED] http://tapestry.sf.net > I am attempting to implement a download button, where the user clicks it > and they are asked to save the contents I stream out. > As far as I can tell.. the best way to go about doing this is to have a > DirectLink with target="_blank" and in the listener method to set the > content type to application/octet-stream and stream it out.. > > I haven't attempted this yet because this doesn't seem a very > "Tapestry-ish" solution. Is there a better way? > > Thanks > > Luke Galea > Software Development > BlueCat <http://www.bluecatnetworks.com/> Networks > 905-762-5225 > > ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Tapestry-developer mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/tapestry-developer
