xsubs Posted December 30, 2007 Share Posted December 30, 2007 Hello everybody. How can i copy the file which being created here: http://torec.net/download.asp?sub_id=12724 to some place in the server? Thanks. Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/ Share on other sites More sharing options...
hitman6003 Posted December 30, 2007 Share Posted December 30, 2007 Use the file functions: http://www.php.net/file_get_contents and/or http://www.php.net/file http://www.php.net/fopen http://www.php.net/fread Or, if available, you could use cURL. Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426008 Share on other sites More sharing options...
xsubs Posted December 30, 2007 Author Share Posted December 30, 2007 What do i do with File_Get_Contents, How can it help me at this situation? Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426023 Share on other sites More sharing options...
hitman6003 Posted December 30, 2007 Share Posted December 30, 2007 file_get_contents reads the data into a variable (assuming the fopen wrappers are enabled). You can then save that data on your server. Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426026 Share on other sites More sharing options...
xsubs Posted December 30, 2007 Author Share Posted December 30, 2007 But this is a Zip file... is it ok? Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426038 Share on other sites More sharing options...
hitman6003 Posted December 30, 2007 Share Posted December 30, 2007 file_get_contents is binary safe, so a zip file will not affect it. Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426041 Share on other sites More sharing options...
xsubs Posted December 30, 2007 Author Share Posted December 30, 2007 I sent you a PM. Please answer me as soon as you can. Thanks. Link to comment https://forums.phpfreaks.com/topic/83721-problem-with-downloading-a-file/#findComment-426054 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.