Welcome Guest, Not a member yet? Register   Sign In
MP4 Force Download
#1

[eluser]JingCleoVil[/eluser]
Hi all,

I am using this helper http://codeigniter.com/wiki/Download_hel...rge_files/ it works perfectly but when I downloaded the file it seems it cant play. Its MP4 format. I already added the mime file in config/mime.php 'mp4' => 'video/mp4'.

The file from ftp is 8.9mb and its same when i forcefully downloaded it.

Is it on the php header part?
#2

[eluser]Ken Verhaegen[/eluser]
Did you try another .mp4-file yet?
The MIME should be ok, but maybe there's a codec error withing the file itself.


http://mobiforge.co.../content-delivery-mobile-devices
Maybe this link helps in any way?
#3

[eluser]JingCleoVil[/eluser]
Yeah i think its any video. I also tried .mov same thing happened.
#4

[eluser]Ken Verhaegen[/eluser]
Probably something goes wrong when the script tries to divide (chunk) the files...
Try to comment out the MIME-sections, so you'll get a decent error code from the script if there is one.
#5

[eluser]InsiteFX[/eluser]
Try adding the mime type to application/config/mimes.php
Code:
'mp4' => 'video/mpeg',
Also you may need to change the file download size in your php.ini file!
Check you apache file also it may not have the mime type in it so add it!

InsiteFX
#6

[eluser]Ken Verhaegen[/eluser]
InsiteFX,
Like he said in the first post, he did that.
And the whole point of the extension he uses is to ignore php.ini settings and download bigger files in chunks (it works, but I can't seem to find out why some files are broken due to lost data)
#7

[eluser]InsiteFX[/eluser]
Give me a link and I'll see if I can play it!
#8

[eluser]JingCleoVil[/eluser]
Guys!

Thanks for quick response. I solved it. I just tweak the .htaccess by using this code


<Files *.mp4>
ForceType applicaton/octet-stream
</Files>

and normal link for the anchor.

<a href="test.com/videofile.mp4">DOWNLOAD</a>
#9

[eluser]czerneev[/eluser]
Hi Jing or everyone,

I'm kinda stuck with the same problem. I managed to save the file and indeed it has the same file size but when I try to open it I get
"Windows Media Player cannot play the file. The Player might not support the file type or might not support the codec that was used to compress the file."

Where the original file plays well.

Your help will be much appreciated.

Thank you.

P.S. I'm newbie so kinda need a bit detailed info =)
#10

[eluser]InsiteFX[/eluser]
Because your Windows does not have the codex to play the file install the versions of QuickTime or RealPlayer and then you will have it.




Theme © iAndrew 2016 - Forum software by © MyBB