Category : sftp

I want to put these files to my SFTP server Array ( [0] => admin/web/uploads/invoice/21-1623165946–invoice.pdf [1] => admin/web/uploads/invoice/4-1623166165–invoice.pdf [2] => admin/web/uploads/invoice-csv/Created-2021-06-15_05-34-22.csv ) with the all permissions eg.0777 in the folder the folder structure will be like this root |–test |–|–(create a directory current date in Y-m-d format and give all permission eg.0777) |–|–|–inside that folder ..

Read more

While trying to connect the server through ftp_ssl_connect I’m facing two issues. $conn_id = ftp_ssl_connect($ftp_server, <port_num>, 20) $login_result = ftp_login( $conn_id, $ftp_user_name, $ftp_user_pass ); In this above command while using the port_num as 22 it showing the message "Couldn’t connect to ssl", but while using 0 as port_num its getting connected. There other issue was, ..

Read more

I’m using phpseclib to connect an sftp server, and I use $sftp->nlist to list the directories. I can list all small directories, but when listing one with more than 8000 files the memory limit is exceeded. I’ve already set ini_set(‘memory_limit’,’128M’) and ini_set(‘max_execution_time’, ‘300’); but it is impossible to wait for the response of the request. ..

Read more

I am trying to Connect and Handle Files in SFTP Server using PHP. But i am getting error ssh2_connect Fatal error: Uncaught Error: Call to undefined function ssh2_connect(). If I installed SSH2 extension will it work for PHP 7 or any other option need. try { $sftp = new SFTPConnection("HOST", 22); $sftp->login("UN", "PWD"); $sftp->uploadFile("/tmp/to_be_sent", "/tmp/to_be_received"); ..

Read more