PHP » GoLang |
login |
register |
about
|
GoLang stream_socket_server
request it (443)
GoLang replacement for PHP's stream_socket_server
[edit | history]
stream_socket_server(PHP 5, PHP 7) stream_socket_server — Create an Internet or Unix domain server socket Description
resource stream_socket_server
( string
$local_socket
[, int &$errno
[, string &$errstr
[, int $flags = STREAM_SERVER_BIND | STREAM_SERVER_LISTEN
[, resource $context
]]]] )
Creates a stream or datagram socket on the specified
This function only creates a socket, to begin accepting connections use stream_socket_accept(). Parameters
Return Values
Returns the created stream, or Examples
Example #1 Using TCP server sockets
<?php The example below shows how to act as a time server which can respond to time queries as shown in an example on stream_socket_client().
Example #2 Using UDP server sockets
<?php Notes
See Also
|
more
Recently updated
more
Most requested
more
Last requests
|