$local_file = 'C:\Users\mycom\Downloads\\'.$file_name;
$server_file = '/HDD1/'.$path.'/'.$file_name;
$ftp_user_name='user';
$ftp_user_pass='password';
$ftp_server='myserver.ipdisk.co.kr';
$conn_id = ftp_connect($ftp_server);
$source = "index.php";
$target = fopen("index.php", "r");
$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
$default_path = ftp_pwd($conn_id);
if (ftp_get($conn_id, $local_file, $server_file, FTP_BINARY)) {
echo "Successfully written to $local_file\n";
} else {
echo "There was a problem\n";
}
ftp_close($conn_id);
我尝试这个但不起作用 我可以看到成功消息,但我找不到下载文件
我该怎么办?