phpseclib\Net\SSH1::interactiveRead PHP Метод

interactiveRead() публичный Метод

Requires PHP 4.3.0 or later due to the use of the stream_select() function. If you see stuff like "^[[00m", you're seeing ANSI escape codes. According to {@link http://support.microsoft.com/kb/101875 How to Enable ANSI.SYS in a Command Window}, "Windows NT does not support ANSI escape sequences in Win32 Console applications", so if you're a Windows user, there's not going to be much recourse.
См. также: self::interactiveRead()
public interactiveRead ( ) : string
Результат string
    function interactiveRead()
    {
        if (!($this->bitmap & self::MASK_LOGIN)) {
            throw new \RuntimeException('Operation disallowed prior to login()');
        }
        if (!($this->bitmap & self::MASK_SHELL) && !$this->_initShell()) {
            throw new \RuntimeException('Unable to initiate an interactive shell session');
        }
        $read = array($this->fsock);
        $write = $except = null;
        if (stream_select($read, $write, $except, 0)) {
            $response = $this->_get_binary_packet();
            return substr($response[self::RESPONSE_DATA], 4);
        } else {
            return '';
        }
    }