MP3 Upload & Download

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Mahesh
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2004 4:48 am
Location: Coimbatore, India
Contact:

MP3 Upload & Download

Post by Mahesh »

Hi,

I am writing code to upload and download MP3 files of size around 75 MB. I would like to do this using http. I am using this code for download this.

header("Cache-control: private");
header("Content-Type: application/mp3");
header('Content-Disposition: attachment; filename='.$file_name);
header("Content-Transfer-Encoding: binary");
readfile($GLOBALS["SHOW_ARCHIVE_PATH"].$file_name);

This code only works for downloading files less than 5 MB. However I need to download larger files.

For uploading I am using the copy function. Here also it does not allow files more than 10 MB.

Can anyone help me with the code to do this?

Thanks.
Last edited by Mahesh on Sat Apr 10, 2004 5:27 am, edited 1 time in total.
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

Are you sure the script doesn't timeout? lookup how to change the maximum execution time.
Mahesh
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2004 4:48 am
Location: Coimbatore, India
Contact:

Post by Mahesh »

Hi,

How to set the timeout settings for this? I am a bit of a rookie to PHP.

Thanks
Mahesh
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

There is only one source, http://www.php.net/manual

It knows everything you wanted to know, and more :)
Post Reply