read

(4.0.2 - 4.0.6 only)

read -- Read from a socket

Description

int read (resource socket_des, string buffer, int length [, int type])

Attenzione

Questa funzione è SPERIMENTALE. Ovvero, il comportamento di questa funzione, il nome di questa funzione, in definitiva TUTTO ciò che è documentato qui può cambiare nei futuri rilasci del PHP SENZA PREAVVISO. Siete avvisati, l'uso di questo modulo è a vostro rischio.

The function read() reads from socket socket_descreated by the accept_connect() function into buffer the number of bytes set by length. Otherwise you can use \n, \t or \0 to end reading. Returns number of bytes that have been read.

Optional type parameter is a named constant:

See also accept_connect(), bind(), connect(), listen(), strerror(), socket_get_status() and write().