When javascript/HTML kicks in the headers have already been sent, there is nothing you can do except offering copy & paste :)
A server-side script that does it for you is not much of a burden, it could be made very light. I think you could get the text from POST and stream it directly without the need to save it server-side. cheers, - ricardo On Mar 11, 5:10 pm, Andiih <andyhaw...@googlemail.com> wrote: > I'm trying to see if it is possible to convert a table on a page to a > csv and offer it to the user for download. Obviously I could grab the > data and post it to the server for some aspx or php to revert it with > the correct content type (or even do it all server side in the 1st > place) but I am trying to figure out if there is a way to generate > this all client side. The only bit I need to figure out is if it is > possible to create a popup with the right headers so the browser > treats it as a file download. > > I have a nasty suspicion the answer may be "no" ... > > Thx in advance > > Andrew