I just moved to the blog and planned to migrate the data in two spaces. but when something went wrong, I thought that PHP could download the file remotely and write a script! 01 & lt ;? Php02if ($ _ GET [xfer]) {03if ($ _ POST [from] & quot;) {04 print & quot; Youfor... I just moved to the blog and planned to migrate the data in two spaces. but when something went wrong, I thought that PHP could remotely download files when the packaged files were too large.
Then I wrote a script!
03 |
if ($_POST[from] == "") { |
04 |
print "You forgot to enter a url."; |
05 |
} else { |
06 |
copy("$_POST[from]", "$_POST[to]"); |
07 |
$size = round((filesize($_POST[to])/1000000), 3); |
08 |
print "transfer complete.
|
09 |
$_POST[from]
|
10 |
$_POST[to] : $size MB"; |
13 |
print " |
14 |
Remote File (please include http ://):
|
However, not all virtual hosts support this function. you have to check whether some functions are enabled. I don't know what functions are supported.