socket_getsockname

socket_getsockname -- 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.

Description

bool socket_getsockname ( resource socket, string addr [, int port])

Atenção

Esta função é EXPERIMENTAL . Isso quer dizer que o comportamento desta função e seu nome , incluindo TUDO o que está documentado aqui pode mudar em futuras versões do PHP , SEM QUALQUER NOTIFICAÇÃO . Esteja avisado , e use esta função por sua própria conta e risco .

Retorna TRUE em caso de sucesso ou FALSE em falhas . socket_getsockname( ) may also return FALSE if the socket type is not any of AF_INET or AF_UNIX , in which case the last socket error code is not updated .