示例#1
0
     echo '<tr><td><h2>' . $count . ' ' . $contacts_results . '</h2>';
     echo '<tr><td>';
     if ($count > 0) {
         echo '<table border="0" cellpadding="0" cellspacing="0" width="100%">';
         echo '<tr>';
         if ($multiselect) {
             echo '<td class="TableHead2" width="16"><input type="checkbox" name="dummy" value="dummy" onclick="javascript:invert_selection()" /></td>';
         }
         echo '<td class="TableHead2">' . $strName . '</td>';
         echo '<td class="TableHead2">' . $strEmail . '</td>';
         echo '</tr>';
         echo $search_results;
         echo '</table>';
     }
 } else {
     $ab1->search_companies($GO_SECURITY->user_id, $query, $search_field, $ab_settings['search_addressbook_id']);
     $search_results = '';
     while ($ab1->next_record()) {
         if ((!$require_email_address || $ab1->f("email") != '') && ($GO_SECURITY->has_permission($GO_SECURITY->user_id, $ab1->f('acl_read')) || $GO_SECURITY->has_permission($GO_SECURITY->user_id, $ab1->f('acl_write')))) {
             $count++;
             $class = "Table1";
             $check = "";
             if ($pass_value == 'email') {
                 if ($ab1->f("email") != "") {
                     $key = array_search($ab1->f("email"), $addresses);
                 } else {
                     $key = false;
                 }
                 if (is_int($key)) {
                     unset($addresses[$key]);
                     $check = "checked";