|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Download Page
I am trying to get a user to download a text file from my server. However when he is redirected to the download page the text file is displayed in the browser.
When I add cfcontent and cfheader tags, the save as dialogue tries to save the download.cfm file and because of IIS restrictions it says the file cannot be found. The relative address of the file is in the variable Code:
#url.file# Thanks in advance! |
|
#2
|
|||
|
|||
|
Some browsers handle this differently, and some make you acknowledge the download twice. Something like this should work though:
<cfcontent type="text/plain" reset="Yes" file="path to file"><cfheader name="Content-disposition" value="attachment; filename=myfile.txt">
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian. How to Post a Question in the Forums |
|
#3
|
|||
|
|||
|
ok, thanks I'll try it again
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > Download Page |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|