Windows 7 install php php-ssh2 extension tutorial (start php error: libssh2.dll loss) start php error: libssh2.dll loss.
Solution: install the php-ssh2 extension.
Windows 7 install php php-ssh2 extension tutorial
To transfer files to the test server, we can see that PHP supports the ssh operation. so we sorted out the installation process and shared it with you.
Installation steps
1. download phpextension ssh2
Http://windows.php.net/downloads/pecl/releases/ssh2/0.12/
Bytes
2. after decompression, there will be three files: libssh2.dll, php_ssh.dll, and php_ssh2.pdb.
3. put php_ssh.dll and php_ssh2.pdb in your php extension directory php/ext.
4. copy libssh2.dll to c:/windows/system32 and c:/windows/syswow64.
5. add extension = php_ssh2.dll to php. ini.
6. restart apache to use php for ssh connection.
Check whether phpinfo () is successfully loaded.
PHP test code
The code is as follows:
$connection = ssh2_connect('192.168.255.128', 22);ssh2_auth_password($connection, 'root', '123456');ssh2_scp_send($connection, 'd:/tmp/test.txt', '/tmp/test.txt', 0644);
+
=
=
=
=
+