listen

(4.0.2 - 4.0.6 only)

listen -- Listens for a connection on a socket

Description

int listen (resource socket, int backlog)

Figyelem

Ez a függvény KÍSÉRLETI JELLEGGEL MŰKÖDIK. Ez azt jelenti, hogy a leírt működés, a függvény neve, azaz BÁRMI, ami itt le van írva, megváltozhat egy későbbi PHP kiadásban MINDEN FIGYELMEZTETÉS NÉLKÜL. Ezt a függvényt csak a saját felelősségedre használd!

After the socket socket has been created using socket() and bound to a name with bind(), it may be told to listen for incoming connections on socket. A maximum of backlog incoming connections will be queued for processing.

listen() is applicable only to sockets with type SOCK_STREAM or SOCK_SEQPACKET.

Returns zero on success, or a negative error code on failure. This code may be passed to strerror() to get a textual explanation of the error.

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