I would not recommend doing it this way for security reasons (I file may not be what it claims to be) - better to download the file and then upload it with FTP. That being said, to do a decent job of it you will need to make use of cURL. I suggest creating a function that accepts the URL of the “resource” you wish to upload, and the path and filename of the eventual destination. Use cURL to grab the file contents and then create, open and write the file on the server in the usual way (use relative paths when doing this part).
Simon Jessey | Keystone Websites
Save $97 on yearly plans with promo code [color=#CC0000]SCJESSEY97[/color]