[Xitami] targeting file downloads
Rick Headly
xitami@lists.xitami.org
Tue, 7 Jun 2005 23:12:12 -0300
------=_Part_94_4018284.1118196732225
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
>=20
> Martin Bleisteiner - said:
>=20
> What about simply renaming the file? Instead "this.mpg" name "this.xxx" s=
o=20
> the browser asks for download and the user simply can rename.
thank you kindly for your input martin! this is certainly an option i will=
=20
consider, if all else fails. my main objective however, is to keep this as=
=20
simple as possible for the end user. we all know how most people (average=
=20
folks) fail to read instructions, and shun things which they so carelessly=
=20
perceive as "geek-talk" or "technical detail". complete 'click and go'=20
automation is my goal, it keeps average folks content ;)
> "Marc Doigny" - said:
>
> The only way you could force the browser not trying to display the file i=
s
> to change the MIME type of the file.
>
> Change the association from "video/mpeg" to "application/octet-stream"
> The visitor will be prompted to "run from current location" or "save".
thank you for your interesting suggestion marc! by this, i assume that you=
=20
are talking about editing the individual headers of each of my files in=20
question. this is not something i've ever experimented with before, but=20
something i plan to look into more deeply in the near future. if it works,=
=20
it has the potential to fuel my imagination for other projects which are=20
currently on my back-burners :)
> "Alex Barna" - said:
>
> That is just what download sites like tucows.com <http://tucows.com> &=20
download.com <http://download.com> do.
> What you need is some java script code for auto download on the page.
> Then clicking on the file in a list brings up a page with the java code.
> Do a search for free java scripts.
interesting that you mention java-script alex, as it's originally where i=
=20
first assumed i'd find a solution. it seems logical to me, that some very=
=20
simple java-script should be able to deal with such a thing rather=20
efficiently. a search of all my favourite java-script sites however, turns=
=20
up nothing of the sort whatsoever.
i'm able to google-up numerous support forums though, only to read posts=
=20
from so many others, who are trying to achieve similar results. most of=20
these threads start out discussing the availability of such pre-written=20
java-script... but then after much confusion and failed tests, they=20
eventually focus their attention around php. this particular php script=20
seems most popular for the purpose:
http://elouai.com/force-download.php=20
on a side note to all of this, i often use a rather nifty little service=
=20
for sending extremely large e-mail attachments (up to 1gb. in size):
http://s5.yousendit.com/
- when downloading files through this service, they never attempt to load=
=20
into an associated program, regardless of their type. for an example of=20
exactly what i'm talking about, please click this direct file-link to a=20
windows-media-video file, and watch how it prompts your download dialog,=20
rather than your file-player:
http://d50.yousendit.com/C/0LJ97YT1TG4M0QY8UE1AT47UL/Use_seat.wmv
because "this particular example" completely eliminates the use of=20
web-pages, it also eliminates the possible use of java-script. this is what=
=20
first gave me the idea that something must be tweaked on their web-server..=
.=20
and my main reason for bringing such a question into the xitami forum.
i'd like to be able to copy whatever it is they're doing.
=20
> "Jeff McDonald" - said:
>
> Why not use a fpt link insted of a http link to the file.
thank you jeff! i assumed this might work as well... 'my' tests however,=
=20
have concluded that left-clicking a direct ftp-link to a media-file 'still'=
=20
makes a call to the file-player (on all 3 of my work-stations). to run thes=
e=20
tests, i've been accessing media-files (via ftp link) which are located on =
a=20
friend's ms-iis server (if that makes any difference).
very bad things happen when i attempt to access my own xitami ftp service=
=20
from within the local network. it's always been this way. i've learned to=
=20
live with it ;)
=20
> "Michael diLorenzo" - said:
>
> An ftp link will open the file the same way an http link will.
i agree 100% michael. thank you for your input :)
>"Brian {Hamilton Kelly}" - said:
>
> What a strange browser your visitors must be using; an FTP server has no
> capability of sending a Content-Type header, so it's purely a binary (or
> text) stream to the client end.
>
> A browser has absolutely no right to invent its own concept of a
> Content-Type, *especially* when acting as an FTP client.
are you suggesting brian, that an ftp link should 'not' call up the=20
file-player?
... they most certainly do, at my location.
have yourselves a pleasant day, and please keep me in mind if anyone=20
happens to discover a fool-proof work-around for this particular quirk. all=
=20
of your comments have been greatly appreciated, thanks again :)
rick
------=_Part_94_4018284.1118196732225
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
<div>
<blockquote class=3D"gmail_quote" style=3D"PADDING-LEFT: 1ex; MARGIN: 0px 0=
px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Martin Bleisteiner - said:<br><b=
r>What about simply renaming the file? Instead "this.mpg" name &q=
uot;
this.xxx" so the browser asks for download and the user simply can ren=
ame.</blockquote><br>thank you kindly for your input martin! this is =
certainly an option i will consider, if all else fails. my main objective h=
owever, is to keep this as simple as possible for the end user. we al=
l know how most people (average folks) fail to read instructions, and shun =
things which they so carelessly perceive as "geek-talk" or "=
technical detail". complete 'click and go' automation is my goal=
, it keeps average folks content ;)
<br><br><br>> "Marc Doigny" - said:<br>><br>> The only w=
ay you could force the browser not trying to display the file is<br>> to=
change the MIME type of the file.<br>><br>> Change the association f=
rom "video/mpeg" to "application/octet-stream"
<br>> The visitor will be prompted to "run from current location&qu=
ot; or "save".<br><br>thank you for your interesting suggestion m=
arc! by this, i assume that you are talking about editing the individ=
ual headers of each of my files in question. this is not something i'=
ve ever experimented with before, but something i plan to look into more de=
eply in the near future. if it works, it has the potential to fuel my imagi=
nation for other projects which are currently on my back-burners :)
<br><br><br>> "Alex Barna" - said:<br>><br>> That is jus=
t what download sites like <a href=3D"http://tucows.com">tucows.com</a> &am=
p; <a href=3D"http://download.com">download.com</a> do.<br>> What you ne=
ed is some java script code for auto download on the page.
<br>> Then clicking on the file in a list brings up a page with the java=
code.<br>> Do a search for free java scripts.<br><br>interesting that y=
ou mention java-script alex, as it's originally where i first assumed i'd f=
ind a solution. it seems logical to me, that some very simple java-sc=
ript should be able to deal with such a thing rather efficiently. a s=
earch of all my favourite java-script sites however, turns up nothing of th=
e sort whatsoever.
</div>
<div> </div>
<div>i'm able to google-up numerous support forums though, only t=
o read posts from so many others, who are trying to achieve similar re=
sults. most of these threads start out discussing the availability of=
such pre-written java-script... but then after much confusion and fai=
led tests, they eventually focus their attention around php. this par=
ticular php script seems most popular for the purpose:
</div>
<div> <a href=3D"http://elouai.com/force-download.php">ht=
tp://elouai.com/force-download.php</a> </div>
<div> </div>
<div>on a side note to all of this, i often use a rather nifty little servi=
ce for sending extremely large e-mail attachments (up to 1gb. in size):</di=
v>
<div> <a href=3D"http://s5.yousendit.com/">http://s5.yous=
endit.com/</a></div>
<div> </div>
<div>- when downloading files through this service, they never attempt to l=
oad into an associated program, regardless of their type. for an exam=
ple of exactly what i'm talking about, please click this direct file-link t=
o a windows-media-video file, and watch how it prompts your download dialog=
, rather than your file-player:
</div>
<div> <a href=3D"http://d50.yousendit.com/C/0LJ97YT1TG4M0=
QY8UE1AT47UL/Use_seat.wmv">http://d50.yousendit.com/C/0LJ97YT1TG4M0QY8UE1AT=
47UL/Use_seat.wmv</a></div>
<div> </div>
<div>because "this particular example" completely eliminates the =
use of web-pages, it also eliminates the possible use of java-script. =
this is what first gave me the idea that something must be tweaked on thei=
r web-server... and my main reason for bringing such a question into the xi=
tami forum.
</div>
<div> </div>
<div>i'd like to be able to copy whatever it is they're doing.<br> </d=
iv>
<div><br>> "Jeff McDonald" - said:<br>><br>> Why not use=
a fpt link insted of a http link to the file.</div>
<div> </div>
<div>thank you jeff! i assumed this might work as well... 'my' tests =
however, have concluded that left-clicking a direct ftp-link to a medi=
a-file 'still' makes a call to the file-player (on all 3 of my work-station=
s). to run these tests, i've been accessing media-files (via ftp link=
) which are located on a friend's ms-iis server (if that makes any differen=
ce).
</div>
<div> </div>
<div>very bad things happen when i attempt to access my own xitami ftp serv=
ice from within the local network. it's always been this way.&nb=
sp; i've learned to live with it ;)</div>
<div> </div>
<div><br>> "Michael diLorenzo" - said:<br>><br>> An ftp =
link will open the file the same way an http link will.</div>
<div> </div>
<div>i agree 100% michael. thank you for your input :)<br><br><br>>=
;"Brian {Hamilton Kelly}" - said:<br>><br>> What a strange =
browser your visitors must be using; an FTP server has no<br>> capabilit=
y of sending a Content-Type header, so it's purely a binary (or
<br>> text) stream to the client end.<br>><br>> A browser has abso=
lutely no right to invent its own concept of a<br>> Content-Type, *espec=
ially* when acting as an FTP client.</div>
<div> </div>
<div>are you suggesting brian, that an ftp link should 'not' call up the fi=
le-player?</div>
<div> </div>
<div>... they most certainly do, at my location.</div>
<div> </div>
<div> </div>
<div>have yourselves a pleasant day, and please keep me in mind if anyone h=
appens to discover a fool-proof work-around for this particular quirk.=
all of your comments have been greatly appreciated, thanks again :)<=
/div>
<div> </div>
<div>rick</div>
<div> </div>
<div> </div>
------=_Part_94_4018284.1118196732225--