[ back to toc ]

ftp

Date: 2002/02/04 10:29

Q:
Good day Peter,
I need to put a button in a page so when I click
it will download an .mdb file from the site to the Office PC.
I'v got this line from my html book but it is not working should I use
perl script to download files?
tell me how.
Best regard,
*NAME-DELETED*
<a href="ftp://data.mdb">Back up</a>
A:
There are two different issues.

1. The format of the file is not correct. The file is on the server, and
therefore you have to specify the full URL to the file. For example:

<a href="ftp://www.yahoo.com/rodpages/data.mdb">Back up</a>

including the name of the FTP site where the file is. There is no way
relatively reference from a web page (http://) to and ftp reachable file
(ftp://).

2. This is not a button but rather a link. If you want to have a button
then you need some server side programming, or JavaScript programming to
direct the browser to the URL.

3. Why do you want it being downloaded using ftp? Downloading a file works
fine with http as well, and in that case you could write relative URL,
like

<a href="data.mdb">Back up</a>

Regards,
Peter

[ back to toc ]