<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/refs.remote.other.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'it',
  ),
  'this' => 
  array (
    0 => 'book.sockets.php',
    1 => 'Sockets',
    2 => 'Sockets',
  ),
  'up' => 
  array (
    0 => 'refs.remote.other.php',
    1 => 'Altri servizi',
  ),
  'prev' => 
  array (
    0 => 'class.snmpexception.php',
    1 => 'SNMPException',
  ),
  'next' => 
  array (
    0 => 'sockets.setup.php',
    1 => 'Installazione/Configurazione',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/sockets/book.xml',
  ),
  'history' => 
  array (
  ),
  'extra_header_links' => 
  array (
    'rel' => 'alternate',
    'href' => '/manual/en/feeds/book.sockets.atom',
    'type' => 'application/atom+xml',
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="book.sockets" class="book">
 
 <h1 class="title">Sockets</h1>
 
 
 <div id="intro.sockets" class="preface">
  <h1 class="title">Introduzione</h1>
  <p class="para">
   The socket extension implements a low-level interface to the socket
   communication functions based on the popular BSD sockets, providing the
   possibility to act as a socket server as well as a client.
  </p>
  <p class="para">
   For a more generic client-side socket interface, see
   <span class="function"><a href="function.stream-socket-client.php" class="function">stream_socket_client()</a></span>, 
   <span class="function"><a href="function.stream-socket-server.php" class="function">stream_socket_server()</a></span>,
   <span class="function"><a href="function.fsockopen.php" class="function">fsockopen()</a></span>, and
   <span class="function"><a href="function.pfsockopen.php" class="function">pfsockopen()</a></span>.
  </p>
  <p class="para">
   When using these functions, it is important to remember that while
   many of them have identical names to their C counterparts, they
   often have different declarations. Please be sure to read the
   descriptions to avoid confusion.
  </p>
  <p class="para">
   Those unfamiliar with socket programming can find a lot
   of useful material in the appropriate Unix man pages, and there is a great
   deal of tutorial information on socket programming in C on the web, much
   of which can be applied, with slight modifications, to socket programming
   in PHP. The <a href="http://www.unixguide.net/network/socketfaq/" class="link external">&raquo;&nbsp;Unix Socket
   FAQ</a> might be a good start.
  </p>
 </div>
 
 
 







 




 







 






 






 




 





<ul class="chunklist chunklist_book"><li><a href="sockets.setup.php">Installazione/Configurazione</a><ul class="chunklist chunklist_book chunklist_children"><li><a href="sockets.installation.php">Installazione</a></li><li><a href="sockets.resources.php">Tipi di risorse</a></li></ul></li><li><a href="sockets.constants.php">Costanti predefinite</a></li><li><a href="sockets.examples.php">Esempi</a></li><li><a href="sockets.errors.php">Socket Errors</a></li><li><a href="ref.sockets.php">Socket Funzioni</a><ul class="chunklist chunklist_book chunklist_children"><li><a href="function.socket-accept.php">socket_accept</a> — Accetta una connessione su un socket</li><li><a href="function.socket-addrinfo-bind.php">socket_addrinfo_bind</a> — Create and bind to a socket from a given addrinfo</li><li><a href="function.socket-addrinfo-connect.php">socket_addrinfo_connect</a> — Create and connect to a socket from a given addrinfo</li><li><a href="function.socket-addrinfo-explain.php">socket_addrinfo_explain</a> — Get information about addrinfo</li><li><a href="function.socket-addrinfo-lookup.php">socket_addrinfo_lookup</a> — Get array with contents of getaddrinfo about the given hostname</li><li><a href="function.socket-atmark.php">socket_atmark</a> — Determines whether socket is at out-of-band mark</li><li><a href="function.socket-bind.php">socket_bind</a> — Bind di un nome ad un socket</li><li><a href="function.socket-clear-error.php">socket_clear_error</a> — Azzera gli erorri di un socket, oppure l'ultimo codice d'errore</li><li><a href="function.socket-close.php">socket_close</a> — Chiude una risorsa di tipo socket</li><li><a href="function.socket-cmsg-space.php">socket_cmsg_space</a> — Calculate message buffer size</li><li><a href="function.socket-connect.php">socket_connect</a> — Inizia una connessione su un socket</li><li><a href="function.socket-create.php">socket_create</a> — Crea un socket (punto terminale di una comunicazione).</li><li><a href="function.socket-create-listen.php">socket_create_listen</a> — Apre un socket per accettare connessioni su una porta</li><li><a href="function.socket-create-pair.php">socket_create_pair</a> — Crea una coppia di socket non distinguibili e li memorizza in una matrice</li><li><a href="function.socket-export-stream.php">socket_export_stream</a> — Export a socket into a stream that encapsulates a socket</li><li><a href="function.socket-get-option.php">socket_get_option</a> — Ottiene le opzioni per un socket</li><li><a href="function.socket-getopt.php">socket_getopt</a> — Alias di socket_get_option</li><li><a href="function.socket-getpeername.php">socket_getpeername</a> — Interroga il lato remoto di un dato socket per ottenere o la combinazione host/porta
     od un percorso Unix, in base al tipo di socket</li><li><a href="function.socket-getsockname.php">socket_getsockname</a> — Interroga il lato locale di un dato socket e restituisce o la combinazione host/porta
     oppure un percorso Unix in base al tipo di socket</li><li><a href="function.socket-import-stream.php">socket_import_stream</a> — Import a stream</li><li><a href="function.socket-last-error.php">socket_last_error</a> — Restituisce l'ultimo errore su un socket.</li><li><a href="function.socket-listen.php">socket_listen</a> — Attende una richiesta di connessione su un socket</li><li><a href="function.socket-read.php">socket_read</a> — Legge fino ad un massimo di byte predefiniti da un socket</li><li><a href="function.socket-recv.php">socket_recv</a> — Riceve i dati da un socket collegato</li><li><a href="function.socket-recvfrom.php">socket_recvfrom</a> — Riceve i dati da un socket, che sia connesso o meno</li><li><a href="function.socket-recvmsg.php">socket_recvmsg</a> — Legge un messaggio</li><li><a href="function.socket-select.php">socket_select</a> — Esegue la system call select() su un set di socket con un dato timeout</li><li><a href="function.socket-send.php">socket_send</a> — Invia i dati ad un socket collegato</li><li><a href="function.socket-sendmsg.php">socket_sendmsg</a> — Manda un messaggio</li><li><a href="function.socket-sendto.php">socket_sendto</a> — Invia un messaggio ad un socket, a prescindere che sia connesso o meno</li><li><a href="function.socket-set-block.php">socket_set_block</a> — Sets blocking mode on a socket</li><li><a href="function.socket-set-nonblock.php">socket_set_nonblock</a> — Attiva la modalit&agrave; &quot;nonblocking&quot; per il descrittore di file fd</li><li><a href="function.socket-set-option.php">socket_set_option</a> — Valorizza le opzioni per un socket</li><li><a href="function.socket-setopt.php">socket_setopt</a> — Alias di socket_set_option</li><li><a href="function.socket-shutdown.php">socket_shutdown</a> — Chiude un socket in ricezione, in invio o in entrambi i sensi</li><li><a href="function.socket-strerror.php">socket_strerror</a> — Restituisce una stringa con la descrizione dell'errore.</li><li><a href="function.socket-write.php">socket_write</a> — Scrive su un socket.</li><li><a href="function.socket-wsaprotocol-info-export.php">socket_wsaprotocol_info_export</a> — Exports the WSAPROTOCOL_INFO Structure</li><li><a href="function.socket-wsaprotocol-info-import.php">socket_wsaprotocol_info_import</a> — Imports a Socket from another Process</li><li><a href="function.socket-wsaprotocol-info-release.php">socket_wsaprotocol_info_release</a> — Releases an exported WSAPROTOCOL_INFO Structure</li></ul></li><li><a href="class.socket.php">Socket</a> — The Socket class</li><li><a href="class.addressinfo.php">AddressInfo</a> — The AddressInfo class</li></ul></div><?php manual_footer($setup); ?>