Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-17-2005, 06:30 PM   PM User | #1
SilentDrive
New Coder

 
Join Date: Dec 2004
Posts: 34
Thanks: 0
Thanked 0 Times in 0 Posts
SilentDrive is an unknown quantity at this point
Link to a file... this might be JS

I want to make a link to download a video file. However when I click it, it opens to a stream... what am I missing??


example of what I got in now...
<a href="http://www.somesite.com/downloads/thefile.avi">TEXT LINK</a>
SilentDrive is offline   Reply With Quote
Old 07-17-2005, 06:45 PM   PM User | #2
cjwsb
Regular Coder

 
Join Date: Oct 2003
Location: The wild blue yonder
Posts: 283
Thanks: 0
Thanked 0 Times in 0 Posts
cjwsb is an unknown quantity at this point
To the best of MY knowledge, what you want to do is impossible, even if you use <embed>, <img> or other tags.

I may be wrong, and would love to be proven so, but in the meantime, might I suggest zipping the avi file and having someone download it that way. They unzip, and watch.

Chris
__________________
My Site | My Blog
cjwsb is offline   Reply With Quote
Old 07-17-2005, 06:53 PM   PM User | #3
SilentDrive
New Coder

 
Join Date: Dec 2004
Posts: 34
Thanks: 0
Thanked 0 Times in 0 Posts
SilentDrive is an unknown quantity at this point
This is a good suggestion... Thanks...
SilentDrive is offline   Reply With Quote
Old 07-17-2005, 09:05 PM   PM User | #4
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,293
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
You could also pass some headers in php. Let me know if you wanna do that.
_Aerospace_Eng_ is offline   Reply With Quote
Old 07-18-2005, 12:41 AM   PM User | #5
SilentDrive
New Coder

 
Join Date: Dec 2004
Posts: 34
Thanks: 0
Thanked 0 Times in 0 Posts
SilentDrive is an unknown quantity at this point
I know nothing about PHP but if you can explain it easily I'll give it a shot...
SilentDrive is offline   Reply With Quote
Old 07-18-2005, 03:09 AM   PM User | #6
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,293
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
You can make a file saved with a .php extension, the only thing in it will be this
PHP Code:
<?
header
("Content-Type: video/avi; name=movie.avi");
header("Content-disposition: attachment; filename=movie.avi");
?>
Change the name to match your movie name change the filename to match the movie file location. If you go to this page it will prompt a download page. You could directly link to this page and the user will be asked to open/save the avi file, but I think the zip method works fine as well.
_Aerospace_Eng_ is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:34 AM.


Advertisement
Log in to turn off these ads.