socket_recvmsg

(PHP 5 >= 5.5.0, PHP 7) Read a message int socket_recvmsg ( resource $socket, string $message [, int $flags ] ) Parameters: socket message flags Returns: This function is currently not documented; only its argument list is available.

socket_recvfrom

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Receives data from a socket whether or not it is connection-oriented int socket_recvfrom ( resource $socket, string &$buf, int $len, int $flags, string &$name [, int &$port ] ) The socket_recvfrom() function receives len bytes of data in buf from name on port port (if the socket is not of type AF_UNIX) using socket. socket_recvfrom() can be used to gather data from both connected

socket_recv

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Receives data from a connected socket int socket_recv ( resource $socket, string &$buf, int $len, int $flags ) The socket_recv() function receives len bytes of data in buf from socket. socket_recv() can be used to gather data from connected sockets. Additionally, one or more flags can be specified to modify the behaviour of the function. buf is passed by reference, so it must be speci

socket_read

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Reads a maximum of length bytes from a socket string socket_read ( resource $socket, int $length [, int $type = PHP_BINARY_READ ] ) The function socket_read() reads from the socket resource socket created by the socket_create() or socket_accept() functions. Parameters: socket A valid socket resource created with socket_create() or socket

socket_listen

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Listens for a connection on a socket bool socket_listen ( resource $socket [, int $backlog = 0 ] ) After the socket socket has been created using socket_create() and bound to a name with socket_bind(), it may be told to listen for incoming connections on socket. socket_listen() is applicable only to sockets of type SOCK_STREAM or SOCK_SEQPACKET. Parameters:

socket_last_error

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Returns the last error on the socket int socket_last_error ([ resource $socket ] ) If a socket resource is passed to this function, the last error which occurred on this particular socket is returned. If the socket resource is omitted, the error code of the last failed socket function is returned. The latter is particularly helpful for functions like socket_create() which don't return a soc

socket_import_stream

(PHP 5 >= 5.4.0, PHP 7) Import a stream resource socket_import_stream ( resource $stream ) Imports a stream that encapsulates a socket into a socket extension resource. Parameters: stream The stream resource to import. Returns: Returns FALSE or NULL on failure. Examples: socket_imp

socket_getsockname

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Queries the local side of the given socket which may either result in host/port or in a Unix filesystem path, dependent on its type bool socket_getsockname ( resource $socket, string &$addr [, int &$port ] ) Note: socket_getsockname() should not be used with AF_UNIX sockets created with socket_connect(). Only sockets created with socket_accept() or a primary server socket foll

socket_getpeername

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Queries the remote side of the given socket which may either result in host/port or in a Unix filesystem path, dependent on its type bool socket_getpeername ( resource $socket, string &$address [, int &$port ] ) Queries the remote side of the given socket which may either result in host/port or in a Unix filesystem path, dependent on its type. Parameters:

socket_getopt

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Alias of socket_get_option() This function is an alias of: socket_get_option().