socket_strerror

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Return a string describing a socket error string socket_strerror ( int $errno ) socket_strerror() takes as its errno parameter a socket error code as returned by socket_last_error() and returns the corresponding explanatory text. Note: Although the error messages generated by the socket extension are in English, the system messages retrieved with this function will appear depending on th

socket_shutdown

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Shuts down a socket for receiving, sending, or both bool socket_shutdown ( resource $socket [, int $how = 2 ] ) The socket_shutdown() function allows you to stop incoming, outgoing or all data (the default) from being sent through the socket Parameters: socket A valid socket resource created with socket_create(). h

socket_setopt

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

socket_set_option

(PHP 4 >= 4.3.0, PHP 5, PHP 7) Sets socket options for the socket bool socket_set_option ( resource $socket, int $level, int $optname, mixed $optval ) The socket_set_option() function sets the option specified by the optname parameter, at the specified protocol level, to the value pointed to by the optval parameter for the socket. Parameters: socket A valid socket reso

socket_set_nonblock

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Sets nonblocking mode for file descriptor fd bool socket_set_nonblock ( resource $socket ) The socket_set_nonblock() function sets the O_NONBLOCK flag on the socket specified by the socket parameter. When an operation (e.g. receive, send, connect, accept, ...) is performed on a non-blocking socket, the script will not pause its execution until it receives a signal or it can perform the op

socket_set_block

(PHP 4 >= 4.2.0, PHP 5, PHP 7) Sets blocking mode on a socket resource bool socket_set_block ( resource $socket ) The socket_set_block() function removes the O_NONBLOCK flag on the socket specified by the socket parameter. When an operation (e.g. receive, send, connect, accept, ...) is performed on a blocking socket, the script will pause its execution until it receives a signal or it can perform the operation.

socket_sendto

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Sends a message to a socket, whether it is connected or not int socket_sendto ( resource $socket, string $buf, int $len, int $flags, string $addr [, int $port = 0 ] ) The function socket_sendto() sends len bytes from buf through the socket socket to the port at the address addr. Parameters: socket A valid socket resource created using s

socket_sendmsg

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

socket_send

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Sends data to a connected socket int socket_send ( resource $socket, string $buf, int $len, int $flags ) The function socket_send() sends len bytes to the socket socket from buf. Parameters: socket A valid socket resource created with socket_create() or socket_accept(). buf A buffer containing the data

socket_select

(PHP 4 >= 4.1.0, PHP 5, PHP 7) Runs the select() system call on the given arrays of sockets with a specified timeout int socket_select ( array &$read, array &$write, array &$except, int $tv_sec [, int $tv_usec = 0 ] ) socket_select() accepts arrays of sockets and waits for them to change status. Those coming with BSD sockets background will recognize that those socket resource arrays are in fact the so-called