ftp_sockets::_data_write_block()publicWP 1.0

Метод класса: ftp_sockets{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$ftp_sockets = new ftp_sockets();
$ftp_sockets->_data_write_block( $mode, $block );
$mode (обязательный)
-
$block (обязательный)
-

Код ftp_sockets::_data_write_block() WP 6.5.2

function _data_write_block($mode, $block) {
	if($mode!=FTP_BINARY) $block=preg_replace("/\r\n|\r|\n/", $this->_eol_code[$this->OS_remote], $block);
	do {
		if(($t=@socket_write($this->_ftp_temp_sock, $block))===FALSE) {
			$this->PushError("_data_write","socket_write", socket_strerror(socket_last_error($this->_ftp_temp_sock)));
			$this->_data_close();
			return FALSE;
		}
		$block=substr($block, $t);
	} while(!empty($block));
	return true;
}