View difference between Paste ID: dcFgkuBF and LaDCq3pZ
SHOW: | | - or go back to the newest paste.
1
<?php
2
$connection = ssh2_connect('мой ip', 22);
3
ssh2_auth_password($connection, 'логин', 'пароль');
4
$stream=ssh2_exec($connection, 'ifconfig' );
5-
stream_set_blocking($connection, true);
5+
stream_set_blocking($stream, true);
6-
echo stream_get_contents($connection);
6+
echo stream_get_contents($stream);