[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

CGI: triggering a file download & having a page appear

Frank Reiff

7/31/2007 9:36:00 AM

Hi,

I'm fairly new to fast-cgi/CGI programming and I have a particular
problem:

When people click on a download link, I want the download to start (zip
file) AND an installation page to appear that explains how to use the
downloaded file.

This is easily done in JavaScript: show the installation page and
trigger the download via the Body.onLoad handler, but it would be nicer
to do it all on the server side..

Is there any way of triggering two HTTP responses for one request?

Thanks for your time.

Best regards,

Frank
--
Posted via http://www.ruby-....

1 Answer

Robert Klemme

7/31/2007 9:43:00 AM

0

2007/7/31, Frank Reiff <reiff@publicspace.net>:
> Hi,
>
> I'm fairly new to fast-cgi/CGI programming and I have a particular
> problem:
>
> When people click on a download link, I want the download to start (zip
> file) AND an installation page to appear that explains how to use the
> downloaded file.
>
> This is easily done in JavaScript: show the installation page and
> trigger the download via the Body.onLoad handler, but it would be nicer
> to do it all on the server side..
>
> Is there any way of triggering two HTTP responses for one request?

No. One request, one response. Maybe you can do a multipart response
but I have no experience with that myself.

Kind regards

robert