我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

PHP snmp返回结果

I use this function for get result by snmp
snmp2_walk("localhost", "private", "OID");

All work fine, but result returns in this form:
STRING: "..."
STRING: "second"

Is there a function to convert this result into a normal string?
From STRING: "second" to second

I believe this is what you're looking for:

snmp_set_quick_print(1); // print just the value, no types
snmp_set_valueretrieval(SNMP_VALUE_PLAIN); // no quotes for strings

http://us1.php.net/manual/en/ref.snmp.php

近期文章

  • 将数据添加到搜索结果中
  • 数据自动插入
  • strtotime返回错误的号码? [重复]
  • 如何使用jquery mobile将页面幻灯片添加到动态创建的列表中?
  • mySQLi查询产生空值,尽管查询在函数之外工作
  • 在下一页获取POST mysql数据
  • 用户列表有限制
  • PHP:对表单使用require_once()?
  • PHP获取多维数组中的值的等级
  • 扩展控制器 - 但如何激活它? (Symfony 2)
  • jquery .submit()在setTimeout中不会向php传递数据
  • PHP如何修复这个奇怪的UNDEFINED OFFSET错误?
  • 使用onClick函数更新数据库信息
  • 将类属性返回为JSON
  • 用PHP翻译大型网站[关闭]
  • 使用PHP cURL发布数据
  • Laravel 3 - RESTful API
  • 检查外部网站的登录
  • 否则如果 - 我做错了什么?
  • 选择最新版本的课程

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华