function search_show($VAR) { if (SESS_LOGGED) { include_once PATH_MODULES . "voip/voip.inc.php"; $db =& DB(); $v = new voip(); $fdids = $v->get_fax_dids(SESS_ACCOUNT); #echo "<pre>".print_r($fdids,true)."</pre>"; if (is_array($fdids)) { foreach ($fdids as $did) { $sql = "UPDATE " . AGILE_DB_PREFIX . "voip_fax SET \n\t\t\t\t\t\taccount_id\t\t= " . $db->qstr(SESS_ACCOUNT) . ", \n\t\t\t\t\t\tsite_id\t\t\t= " . $db->qstr(DEFAULT_SITE) . " \n\t\t\t\t\t\tWHERE dst = " . $db->qstr($did); $db->Execute($sql); #echo "did=$did ".$sql."<br>"; } } unset($db); } $type = "search"; $this->method["{$type}"] = split(",", $this->method["{$type}"]); $db = new CORE_database(); $db->search_show($VAR, $this, $type); }