socket_addrinfo_lookup

(PHP 7 >= 7.2.0)

socket_addrinfo_lookupGet array with contents of getaddrinfo about the given hostname

说明

socket_addrinfo_lookup ( string $host [, string $service [, array $hints ]] ) : array

Lookup different ways we can connect to host. The returned array contains a set of resources that we can bind to using socket_addrinfo_bind().

参数

host

Hostname to search.

service

The service to connect to. If service is a name, it is translated to the corresponding port number.

hints

Hints provide criteria for selecting addresses returned. You may specify the hints as defined by getadrinfo.

返回值

Returns an array of AddrInfo resource handles that can be used with the other socket_addrinfo functions.

参见

相关文章
php eventbuffer write contents of the buffer to a file or socketphp date/time 函数 get info about given date formatted according to the specified formatphp date/time 函数 returns associative array with detailed info about given datephp date/time 函数 returns an array with information about sunset/sunrise and twilight begin/endphp gnupg 函数 returns an array with information about all keys that matches the given patternphp imap 函数 this function returns an array of messages matching the given search criteriaphp mailparse 函数 returns an associative array of info about the messagephp ncurses 函数 control use of environment information about terminal sizephp oci8 函数 returns the next row from a query as an associative arrayphp postgresql 函数 sends a request to execute a prepared statement with given parameters and waits for the resultphp socket 函数 create and bind to a socket from a given addrinfophp socket 函数 create and connect to a socket from a given addrinfophp socket 函数 get information about addrinfophp socket 函数 get array with contents of getaddrinfo about the given hostnamephp socket 函数 creates a pair of indistinguishable sockets and stores them in an arrayphp socket 函数 queries the remote side of the given socket which may either result in host/port or in a unix filesystem path dependent on its typephp socket 函数 queries the local side of the given socket which may either result in host/port or in a unix filesystem path dependent on its typephp socket 函数 runs the select system call on the given arrays of sockets with a specified timeoutphp sqlite 函数 execute a query against a given database and returns an arrayphp svn 函数 returns a stream to access the contents of a file from a given version of the fs
关注编程学问公众号