Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Hyperlink to a textfile
Message
 
To
25/03/2004 15:54:16
Jerry Tovar
Dana Corporation Dana It
Maumee, Ohio, United States
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
00889776
Message ID:
00889825
Views:
22
This message has been marked as the solution to the initial question of the thread.
>I have a web page that contains hyperlinks to text files so that the user can click the file and download it.
>
>However, if I name the file 'myfile.txt' and hyperlink it, when the user clicks the link, the data is rendered in the users browser. But what I really want is for the browser's Save AS dialog to display asking the user to save the file.
>
>Is there anyway that I can make the hyperlink download the file vs opening the file?
>
>Thanks,
>
>Jerry

You have to change the header that the server send to your browser bofore the file.
In IIS, you can set it to an entire folder in the property page of the folder.
Add : content-disposition = attachment to the folder and all files under this folder will promt for save when viewed in internet explorer.
If we exchange an apple, we both get an apple.
But if we exchange an idea, we both get 2 ideas, cool...


Gérald Santerre
Independant programmer - internet or intranet stuff - always looking for contracts big or small :)
http://www.siteintranet.qc.ca
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform