Trigger file download on a page with content

Posted by jeffreyveon on Stack Overflow See other posts from Stack Overflow or by jeffreyveon
Published on 2010-05-27T17:13:01Z Indexed on 2010/05/27 17:21 UTC
Read the original article Hit count: 134

Filed under:
|
|

I have seen many websites triggering a file save-as dialog on a page with existing HTML content. How do they do this?

I know about setting the right headers such as Content-disposition etc. but when I do that, the content of the page does not load, and immediately the file download is triggered...

© Stack Overflow or respective owner

Related posts about php

Related posts about html