<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.snmp.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'it',
  ),
  'this' => 
  array (
    0 => 'function.snmpget.php',
    1 => 'snmpget',
    2 => 'Fetch an SNMP object',
  ),
  'up' => 
  array (
    0 => 'ref.snmp.php',
    1 => 'SNMP Funzioni',
  ),
  'prev' => 
  array (
    0 => 'function.snmp3-walk.php',
    1 => 'snmp3_walk',
  ),
  'next' => 
  array (
    0 => 'function.snmpgetnext.php',
    1 => 'snmpgetnext',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/snmp/functions/snmpget.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.snmpget" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">snmpget</h1>
  <p class="verinfo">(PHP 4, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">snmpget</span> &mdash; <span class="dc-title">Fetch an <abbr title="Simple Network Management Protocol">SNMP</abbr> object</span></p>

 </div>
 <div class="refsect1 description" id="refsect1-function.snmpget-description">
  <h3 class="title">Descrizione</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>snmpget</strong></span>(<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$hostname</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$community</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><span class="type"><a href="language.types.array.php" class="type array">array</a></span>|<span class="type"><a href="language.types.string.php" class="type string">string</a></span></span> <code class="parameter">$object_id</code></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$timeout</code><span class="initializer"> = -1</span></span>,<br>&nbsp;&nbsp;&nbsp;&nbsp;<span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$retries</code><span class="initializer"> = -1</span></span><br>): <span class="type"><a href="language.types.mixed.php" class="type mixed">mixed</a></span></div>


  <p class="simpara">
   The <span class="function"><strong>snmpget()</strong></span> function is used to read the
   value of an <abbr title="Simple Network Management Protocol">SNMP</abbr> object specified by the
   <code class="parameter">object_id</code>.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.snmpget-parameters">
  <h3 class="title">Elenco dei parametri</h3>
  <dl>
   
    <dt><code class="parameter">hostname</code></dt>
    <dd>
     <span class="simpara">
      The <abbr title="Simple Network Management Protocol">SNMP</abbr> agent.
     </span>
    </dd>
   
   
    <dt><code class="parameter">community</code></dt>
    <dd>
     <span class="simpara">
      The read community.
     </span>
    </dd>
   
   
    <dt><code class="parameter">object_id</code></dt>
    <dd>
     <span class="simpara">
      The <abbr title="Simple Network Management Protocol">SNMP</abbr> object.
     </span>
    </dd>
   
   
    <dt><code class="parameter">timeout</code></dt>
    <dd>
     <span class="simpara">
      The number of microseconds until the first timeout.
     </span>
    </dd>
   
   
    <dt><code class="parameter">retries</code></dt>
    <dd>
     <span class="simpara">
      The number of times to retry if timeouts occur.
     </span>
    </dd>
   
  </dl>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.snmpget-returnvalues">
  <h3 class="title">Valori restituiti</h3>
  <p class="simpara">
   Returns <abbr title="Simple Network Management Protocol">SNMP</abbr> object value on success or <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> on error.
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-function.snmpget-examples">
  <h3 class="title">Esempi</h3>
  <div class="example" id="example-1">
   <p><strong>Example #1 Using <span class="function"><strong>snmpget()</strong></span></strong></p>
   <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />$syscontact </span><span style="color: #007700">= </span><span style="color: #0000BB">snmpget</span><span style="color: #007700">(</span><span style="color: #DD0000">"127.0.0.1"</span><span style="color: #007700">, </span><span style="color: #DD0000">"public"</span><span style="color: #007700">, </span><span style="color: #DD0000">"system.SysContact.0"</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
   </div>

  </div>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.snmpget-seealso">
  <h3 class="title">Vedere anche:</h3>
  <ul class="simplelist">
   <li><span class="function"><a href="function.snmpset.php" class="function" rel="rdfs-seeAlso">snmpset()</a> - Set the value of an SNMP object</span></li>
  </ul>
 </div>


</div><?php manual_footer($setup); ?>