Wait, never mind. I have had my head in XML mode, I forgot about StreamResponses and this page: http://wiki.apache.org/tapestry/Tapestry5HowToStreamAnExistingBinaryFile
Sorry! Carl Crowder wrote: > Hi again, > > My app needs to serve JNLP files, and these files are dynamically > generated. I'm doing this by simply having the tapestry page render a > template as normal, but using the JNLP element as the page root. I then > set the content type on the page to be the JNLP MIME-type. > > This all works fine and it serves a page which I can then run with WebStart. > > The only problem is the tapestry page is called "app", so the file you > download is also called "app". This is fine when running the app from > within a browser, because of the MIME-type. However I want to allow > users to save the file on their computer to run the app offline. If you > save the file it gets saved as just "app" so, on Windows at least, > double clicking doesn't automatically run WebStart. > > I want to have the file returned be called "app.jnlp" to overcome this. > > Firstly, is the way I'm doing this the best way to serve dynamically > generated JNLPs? > > Secondly, how can I set the page name (or file returned name) to be > "app.jnlp"? I thought about having a dummy page called "app" which just > had a single "jnlp" component which did the work, so "app.jnlp" would > work I think, but that seems like a massive hack. > > Any help would be greatly appreciated :) > > Carl > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]