On Thu, Oct 16, 2008 at 2:02 PM, Nathan Rixham <nrixham@xxxxxxxxx> wrote: > Jay Moore wrote: > >> Greetings list! >> >> Say I want to copy a jpg from a remote server onto mine, using PHP. Right >> now, my script opens a socket to the remote server, and opens the image >> file. It copies its contents into a dummy variable, opens a new file on my >> server, and dumps the contents of the dummy variable into the new file. >> >> For reasons I cannot figure out, it is not working the way I want. Rather >> than display the image, I get an nothing when opening it in an image viewer. >> [snip] >> Code follows: >> >> [/snip] >> --------- >> >> I have trimmed the code some, and omitted the part where I remove the HTTP >> headers and other information I do not need. >> >> Why isn't this working for me? >> >> Thanks in advance, >> Jay >> > > I have used cURL for something similar to grab an audio file from a remote server. That may be an option as well -- Bastien Cat, the other other white meat