Jump to content

php ftp upload


brown2005

Recommended Posts

$local_file = $_FILES['txt_file']['tmp_name'];

$destination_file = "/".basename($_FILES['txt_file']['name']);

$ftp_server = "";
$ftp_user_name = "";
$ftp_user_pass = "";

$conn_id = ftp_connect($ftp_server);

$login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);

 

can i use this on any website or does it need something installed to use it.. i have tried this on site i own.. to try and get to upload to another i own. but i get

 

Fatal error: Call to undefined function ftp_connect() in /customers/fantasy-comps.com/fantasy-comps.com/httpd.www/index.php on line 14

 

$conn_id = ftp_connect($ftp_server); <----------- line 14

Link to comment
https://forums.phpfreaks.com/topic/94341-php-ftp-upload/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.