Download file from within CFWindow
I have a CFwindow that I want the user to be able to click on a buttom to create a zip archive of some files. I have the window and the zipping part working correctly, and I am using cfheader and cfcontent to deliver the zipped file to the browser, yet when it tries to do the cfcontent part, it hangs the browser and never prompts to download.
Here is some sample code im doing for the cfcontent:
<cfif isDefined('form.zip_button')>
<cfzip action="zip" file="#application.webroot#\_ziptemp\#session.username#.zip" filter="*.jpg"
overwrite="yes" recurse="yes" source="#application.userroot#\#session.userfolder#" storepath="yes"></cfzip>
<cfheader name="Content-disposition" value="inline; filename=#session.username#.zip">
<cfcontent file="#application.webroot#\_ziptemp\#session.username#.zip" type="application/x-zip-compressed" deletefile="yes">
</cfif>
Anyone have any ideas how to pull this off?
Thanks
