Welcome to WebmasterWorld Guest from 54.82.99.169

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

Sending files via ftp with a php script

without having ftp enabled?

     
2:51 am on Aug 10, 2009 (gmt 0)

Preferred Member

10+ Year Member

joined:Nov 2, 2005
posts:505
votes: 0


Since I shut off ftp on my server I haven't been able to send any files through ftp. Is there a workaround for this?

I use sftp on the ssh port to do my ftp dealings, is there anyway I can use that to send this file to a remote ftp server?

This is the error I get in my script. I've not made any changes to it, since it stopped working (other than disabling the ftp service from running):

Connected to uploads.x.com, for user x!

Warning: ftp_put() [function.ftp-put]: Type set to A. in /home/xx/public_html/xx/upload.php on line 423
uploads.x.com: FTP upload has failed!

This is line 423:
$upload = ftp_put( $conn_id, $ftpdestinationfile, $ftpsourcefile, FTP_ASCII );

I can also connect manually to uploads.x.com , so it isn't as if my account is broken.

4:01 pm on Aug 11, 2009 (gmt 0)

Administrator

WebmasterWorld Administrator jatar_k is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:July 24, 2001
posts:15756
votes: 0


funny, I found this as the first result in my search
[webmasterworld.com...]

obviously the ftp functions as is won't work since ftp ports are probably closed. Look into that thread and sftp.