<HTML ><HEAD ><TITLE >snmp_set_quick_print</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK REL="HOME" TITLE="PHP Manual" HREF="index.html"><LINK REL="UP" TITLE="SNMP functions" HREF="ref.snmp.html"><LINK REL="PREVIOUS" TITLE="snmp_get_quick_print" HREF="function.snmp-get-quick-print.html"><LINK REL="NEXT" TITLE="snmpget" HREF="function.snmpget.html"><META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=ISO-8859-1"></HEAD ><BODY CLASS="refentry" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#840084" ALINK="#0000FF" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="3" ALIGN="center" >PHP Manual</TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="bottom" ><A HREF="function.snmp-get-quick-print.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="80%" ALIGN="center" VALIGN="bottom" ></TD ><TD WIDTH="10%" ALIGN="right" VALIGN="bottom" ><A HREF="function.snmpget.html" ACCESSKEY="N" >Next</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><H1 ><A NAME="function.snmp-set-quick-print" ></A >snmp_set_quick_print</H1 ><DIV CLASS="refnamediv" ><A NAME="AEN86580" ></A ><P > (PHP 3>= 3.0.8, PHP 4 )</P >snmp_set_quick_print -- Set the value of quick_print within the UCD SNMP library </DIV ><DIV CLASS="refsect1" ><A NAME="AEN86583" ></A ><H2 >Description</H2 >void <B CLASS="methodname" >snmp_set_quick_print</B > ( bool quick_print)<BR ></BR ><P > Sets the value of quick_print within the UCD SNMP library. When this is set (1), the SNMP library will return 'quick printed' values. This means that just the value will be printed. When quick_print is not enabled (default) the UCD SNMP library prints extra information including the type of the value (i.e. IpAddress or OID). Additionally, if quick_print is not enabled, the library prints additional hex values for all strings of three characters or less. </P ><P > Setting quick_print is often used when using the information returned rather then displaying it. <DIV CLASS="informalexample" ><A NAME="AEN86593" ></A ><P ></P ><TABLE BORDER="0" BGCOLOR="#E0E0E0" CELLPADDING="5" ><TR ><TD ><PRE CLASS="php" >snmp_set_quick_print(0); $a = snmpget("127.0.0.1", "public", ".1.3.6.1.2.1.2.2.1.9.1"); echo "$a<BR>\n"; snmp_set_quick_print(1); $a = snmpget("127.0.0.1", "public", ".1.3.6.1.2.1.2.2.1.9.1"); echo "$a<BR>\n";</PRE ></TD ></TR ></TABLE ><P ></P ></DIV > </P ><P > The first value printed might be: 'Timeticks: (0) 0:00:00.00', whereas with quick_print enabled, just '0:00:00.00' would be printed. </P ><P > By default the UCD SNMP library returns verbose values, quick_print is used to return only the value. </P ><P > Currently strings are still returned with extra quotes, this will be corrected in a later release. </P ><P > <B CLASS="function" >snmp_set_quick_print()</B > is only available when using the UCD SNMP library. This function is not available when using the Windows SNMP library. </P ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="function.snmp-get-quick-print.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Home</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="function.snmpget.html" ACCESSKEY="N" >Next</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >snmp_get_quick_print</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="ref.snmp.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >snmpget</TD ></TR ></TABLE ></DIV ></BODY ></HTML >