Reputation:
How can we copy image file from source(another server) to destination(our server) without using copy() of php.
Is there any other way possible for it?
Thanks..
Upvotes: 0
Views: 590
Reputation:
<?php
$url="http://foo.com/foo.jpg";
$name="foo.jpg";
$img= file_get_contents($url);
file_put_contents($name,$img);
?>
Upvotes: 3