Reply
header, readfile failure
Old 10-24-2009, 07:05 AM header, readfile failure
Junior Talker

Posts: 4
Name: Karolis
Trades: 0
PHP Code:
header('Content-type: audio/mpeg');
header('Content-disposition: attachment; filename='.seo_url($data['song_singer']."_-_".$data['song_name']).'.mp3');

readfile(URL($data['song_url'])); 
I'm using that code. But downloaded song cannot be player by some music players, such as Songbird, or on mobile phone.

What should i do ?
Sniuff is offline
Reply With Quote
View Public Profile
 
 
When You Register, These Ads Go Away!
Old 10-28-2009, 08:58 AM Re: header, readfile failure
Extreme Talker

Posts: 172
Trades: 0
Can it be played with OTHER players?
__________________
Daniel, Helpdesk Leader
Hosting24.com Web Hosting - First class web hosting services.
Reseller Hosting - Provide unlimited disk space and bandwidth!
Hosting24 is offline
Reply With Quote
View Public Profile
 
Old 10-28-2009, 03:59 PM Re: header, readfile failure
Junior Talker

Posts: 4
Name: Karolis
Trades: 0
Quote:
Originally Posted by Hosting24 View Post
Can it be played with OTHER players?
Yes, it can be played with Winamp or WMP
Sniuff is offline
Reply With Quote
View Public Profile
 
Old 10-29-2009, 06:06 AM Re: header, readfile failure
Extreme Talker

Posts: 172
Trades: 0
May I ask why don't you use direct link to file?
__________________
Daniel, Helpdesk Leader
Hosting24.com Web Hosting - First class web hosting services.
Reseller Hosting - Provide unlimited disk space and bandwidth!
Hosting24 is offline
Reply With Quote
View Public Profile
 
Old 10-29-2009, 06:09 AM Re: header, readfile failure
Junior Talker

Posts: 4
Name: Karolis
Trades: 0
Quote:
Originally Posted by Hosting24 View Post
May I ask why don't you use direct link to file?
Because the real file name is 45136541.mp3 (smth like that) and i want to make them user friendly.
Sniuff is offline
Reply With Quote
View Public Profile
 
Old 10-29-2009, 01:57 PM Re: header, readfile failure
mtishetsky's Avatar
King Spam Talker

Posts: 1,166
Name: Mike
Location: Mataro, Spain
Trades: 0
Quote:
Originally Posted by Sniuff View Post
Because the real file name is 45136541.mp3 (smth like that) and i want to make them user friendly.
Why not to create a symlink with proper file name?
__________________
mtishetsky is offline
Reply With Quote
View Public Profile Visit mtishetsky's homepage!
 
Reply     « Reply to header, readfile failure
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 



Page generated in 1.05861 seconds with 13 queries