Snippets

Download & save a remote image on your server using PHP

Easy way to download and save a remote image on your own server, using php.

$image = file_get_contents('http://www.url.com/image.jpg');
file_put_contents('/images/image.jpg', $image); //Where to save the image on your server

Share this snippet