Actually, that is the correct path. Which is why I don't understand why
it's not working. And as a user I'm using myself... waitaminute, the
folders are created by the user www, and I argilent may not have write
permission, maybe that's why it's not working. I should try with a
folder I create as me to see if I can write to it.

- Victor >

-----Original Message-----
Sent: Monday, September 02, 2002 9:46 PM
Subject: [PHP] Re: ftp question


Your script upload the file to
are you sure that is the correct path name? If its not, just put the
name and not only a part of it.

Merci de nous avoir choisi. - Thanks you for your choice.
Nicos - CHAILLAN Nicolas
[EMAIL PROTECTED] - Hébergement Group. - Hébergement de sites Internet
"Victor" <[EMAIL PROTECTED]> a écrit dans le message de news:
000001c252ea$36e90160$[EMAIL PROTECTED]
> I took the scriopt from php manual and adapted it to my needs, but I
> an error:
> Warning: ftp_put(): user_pictures/vic/: No such file or directory in
> /home/victor/argilent-www/sites/kodak/upload_picture.php on line 103
> This is the code:
> # set up basic connection
> $conn_id = ftp_connect($ftp_server);
> # login with username and password
> $login_result = ftp_login($conn_id, $ftp_user, $ftp_pass);
> # check connection
> if ((!$conn_id) || (!$login_result)) {
> echo 'FTP connection has failed.';
> exit;
> }
> $destination = $picture_location.'/'.$f_username.'/';
> # upload the file
> $upload = ftp_put($conn_id, $destination, $picture, FTP_BINARY);
> # check upload status
> if (!$upload) {
> echo 'FTP upload has failed.';
> }
> # close the FTP stream
> ftp_close($conn_id);
> I added the destination variable so that I can easily edit the
> destination if I sweitch servers, I'm guessing the error occurs
> php doesn't know where to take the file from?! I'm guessing here, but
> would be nice if someone tough me a bit more about ftp with php.
> user_pictures/vic is the directory the $picture has to go in, but I
> dunno why it doesn't work.
> - Victor >
> ______________________________________________________________________
> Post your free ad now!

PHP General Mailing List (
To unsubscribe, visit:

Post your free ad now!

PHP General Mailing List (
To unsubscribe, visit:

Reply via email to