faqts : Computers : Programming : Languages : JavaScript

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

10 of 19 people (53%) answered Yes
Recently 8 of 10 people (80%) answered Yes

Entry

How can trap clientside download path for file transfers?
Can I save a cookie at the client, with the file path of a file he recently downloaded

Apr 5th, 2008 20:02
ha mo, Colin Fraser, bart, Julio Aragao,


Simply put, why bother? A very complex and unreliable solution is needed 
here. 
Downloads are controlled by the client, a script will not make them any 
more efficient. Your best bet would be to make sure that your links to 
downloadable files are always accurate and relevant. Having said that, 
what you may want to try is a multi-pronged approach: 
Set a cookie that contains the download path, 
Get the cookie and the data it contains, applying it as varaibles and 
then charge the link, set the file up and let it download.
Of course, this assumes that the user wants two files placed in the same 
location on their hard drive, that they have cookies switched on, and 
that you are a clever enough script writer to achive all this. 
There may be another, more reliable solution, but it would be even more 
complex I would suggest. At some stage the law of diminishing returns 
should apply somewhere here...
http://www.businessian.com
http://www.computerstan.com
http://www.financestan.com
http://www.healthstan.com
http://www.internetstan.com
http://www.moneyenews.com
http://www.technologystan.com
http://www.zobab.com
http://www.healthinhealth.com