tommyboy123x Posted May 27, 2007 Share Posted May 27, 2007 so.. first time posting without a question this has been bothering me for a while but i've seen about 20 threads on forums where people ask how to download a file to their server from a remote location.... i found this because i was trying to find it myself So anyways, the trick is to use the copy function... copy("$fileURL", "$destination"); for $fileURL, you input something like "http://www.TheSiteWithFiles.com/file/directory/thefile.jpg" for $destination, you do not put an opening slash, and write a relative path, such as "members/content/TheSiteWithFiles/thefile.jpg" i figure i dont really come around to this forum unless i need help, so i hope this can help someone who searches i'm not really sure if this is the right place to post this but i saw no better fitting place other than "FAQ/Code Snippet Repository" which is read only. Quote Link to comment https://forums.phpfreaks.com/topic/53119-solved-remote-file-download-upload-from-url/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.