Because want to do a test server to send file requirements, see PHP support SSH operation, so sorted out the installation process, and share with you.
Installation steps
1. Download PHP extension SSH2
Download Address http://windows.php.net/downloads/pecl/releases/ssh2/0.12/
According to their version of PHP to download, I use thread-safe, so download is Php_ssh2-0.12-5.4-ts-vc9-x86.zip
2. After the decompression, there will be three files, Libssh2.dll, Php_ssh.dll, php_ssh2.pdb.
3. Place Php_ssh.dll and php_ssh2.pdb under php/ext/under your PHP extensions directory.
4. Copy Libssh2.dll to C:/windows/system32 and c:/windows/syswow64
5. Join Extension=php_ssh2.dll in PHP.ini
6. Restart Apache, you can use PHP to perform an SSH connection operation.
View Phpinfo (), whether there is a display PHP_SSH2 extended load success.
PHP Test Code
Copy Code code as follows:
<?php
$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);
Test Effect Diagram: