The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.
$new_file_name = "filename.jpg";
$file_a = "$form_image_a";
$remote_file = "$new_file_name";
$ftp_host = "hostname";
$conn_id = ftp_connect($ftp_host);
$ftp_user_name = "username";
$ftp_user_pass = "password";
$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
if(ftp_put($conn_id, $remote_file, $file_a, FTP_BINARY))
{ print("Successfully uploaded $file_a \n"); }
else
{ print("There was a problem while uploading $file_a \n"); }
ftp_close($conn_id);
?>
What's wrong with that? Please.
Can finally get this project finished now!
And use more exclamation marks in sentences!
Assuming they are true, first thing I'd try is
ftp_pasv($conn_id, true);
after the ftp_login. Might be you have firewall problems.
> Woah , i regret looking at this now.
Ha ha. Behold, the realm of geeks and nerds.
> You've forgotton to change the hostname!
Good God, man, I do hope that was a joke! Please, have a bit more faith in me than that!
> >
> $new_file_name = "filename.jpg";
>
> $file_a = "$form_image_a";
> $remote_file = "$new_file_name";
> $ftp_host = "hostname";
> $conn_id = ftp_connect($ftp_host);
>
> $ftp_user_name = "username";
> $ftp_user_pass = "password";
>
> $login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
>
> if(ftp_put($conn_id, $remote_file, $file_a, FTP_BINARY))
> { print("Successfully uploaded $file_a \n"); }
> else
> { print("There was a problem while uploading $file_a \n");
> }
>
> ftp_close($conn_id);
>
> ?>
I have your problem!
> $ftp_host = "hostname";
You've forgotton to change the hostname!