/** * This method is used to display all ppp active * @return type array */ public function getAll() { $sentence = new SentenceUtil(); $sentence->fromCommand("/ppp/active/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No PPP Active To Set, Please Your Add PPP Active"; } }
/** * This method used for get all web proxy config * @return type array */ public function getAll() { $sentence = new SentenceUtil(); $sentence->fromCommand("/ip/proxy/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Ip Proxy To Set, Please Your Add Ip Proxy"; } }
/** * * @param type $id string * @return type array * */ public function detail($id) { $sentence = new SentenceUtil(); $sentence->fromCommand("/ip/firewall/service-port/print"); $sentence->where(".id", "=", $id); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Ip Firewall Service-Port With This id = " . $id; } }
/** * This method is used to display hotspot cookie * in detail based on the id * @param string $id * @return array * */ public function detail($id) { $sentence = new SentenceUtil(); $sentence->fromCommand("/ip/hotspot/cookie/print"); $sentence->where(".id", "=", $id); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No IP Hotspot Cookie With This id = " . $id; } }
/** * This method used for get all interface ppp-sever * @return array */ public function getAll() { $sentence = new SentenceUtil(); $sentence->fromCommand("/interface/ppp-server/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Interface PPP Server To Set, Please Your Add Interface PPP Server"; } }
/** * This method is used to display all web-acces * @return type array * */ public function get_all_web_access() { $sentence = new SentenceUtil(); $sentence->fromCommand('/ip/accounting/web-access/getall'); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Ip Accounting web-access To Set, Please Your Add Ip Accounting web-access"; } }
/** * This method is used to display one vlan * in detail based on the id * @param type $id string * @return type array * */ public function detail($id) { $sentence = new SentenceUtil(); $sentence->fromCommand("/interface/vlan/print"); $sentence->where(".id", "=", $id); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Interface VLAN With This id = " . $id; } }
/** * This method is used to display all system routerboard * @return type array */ public function get_all_routerboard() { $sentence = new SentenceUtil(); $sentence->fromCommand("/system/routerboard/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } }
/** * This method is used to display one dns cache all * in detail based on the id * @param type $id string * @return type array * */ public function detailCacheAll($id) { $sentence = new SentenceUtil(); $sentence->fromCommand("/ip/dns/cache/all/print"); $sentence->where(".id", "=", $id); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Ip DNS Cache All With This Id = " . $id; } }
/** * This method is used to display one layer7 protocol * in detail based on the id * @param type $id string * @return type array * */ public function detail($id) { $sentence = new SentenceUtil(); $sentence->fromCommand("/ip/firewall/layer7-protocol/print"); $sentence->where(".id", "=", $id); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No IP Firewall Layer7 Protocol With This id = " . $id; } }
/** * This method used for get all system scheduler * @return type array */ public function getAll() { $sentence = new SentenceUtil(); $sentence->fromCommand("/system/scheduler/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No System Scheduler To Set, Please Your Add System Scheduler"; } }
/** * This method used for get all interface Bridge Settings * @return type array */ public function get_all_bridge_settings() { $sentence = new SentenceUtil(); $sentence->fromCommand("/interface/bridge/settings/getall"); $this->talker->send($sentence); $rs = $this->talker->getResult(); $i = 0; if ($i < $rs->size()) { return $rs->getResultArray(); } else { return "No Interface Bridge Settings To Set, Please Your Add Interface Bridge Settings"; } return $this->query(''); }