/** @deprecated */ public static function searchContacts($unUsed = null, $where = '', $unUsed2 = '', $days = 0) { trigger_error("The CContact::searchContacts() method has been deprecated and will be removed in v4.0. Use CContact->search() instead.", E_USER_NOTICE); $contact = new CContact(); return $contact->search($where, $days); }
die('You should not access this file directly.'); } // @todo convert to template global $AppUI, $tab, $m; $days = $tab == 0 ? 30 : 0; $searchString = w2PgetParam($_POST, 'search_string', ''); if ('' == $searchString) { $searchString = 0 < $tab && $tab < 27 ? chr(64 + $tab) : ''; $searchString = 0 == $tab ? '' : $searchString; } else { $AppUI->setState('ContactsIdxTab', 27); } $AppUI->setState('ContIdxWhere', $searchString); $where = $AppUI->getState('ContIdxWhere') ? $AppUI->getState('ContIdxWhere') : '%'; $contact = new CContact(); $rows = $contact->search($where, $days); $countries = w2PgetSysVal('GlobalCountries'); unset($carr); $carrWidth = 4; $carrHeight = 4; $rn = count($rows); $t = ceil($rn / $carrWidth); if ($rn < $carrWidth * $carrHeight) { $i = 0; for ($y = 0; $y < $carrWidth; $y++) { $x = 0; while ($x < $carrHeight && isset($rows[$i]) && ($row = $rows[$i])) { $carr[$y][] = $row; $x++; $i++; }