/** * Show View modify Page * * @author Duc Kien Tran * @since OBM 1.0 * @param string $order Current field order (get by above print_config_title function) * @param address $ab Addressbook object * @param int $page Contact, Member or Company */ function print_config_content($order, $ab, $page) { global $strSexes, $GO_USERS; $db = new db(); for ($i = 0; $i < count($order); $i++) { switch ($order[$i]) { case 'email': if ($page == 0) { echo "<td nowrap>" . mail_to(empty_to_stripe($ab->f("email")), empty_to_stripe($ab->f("email")), 'normal', true, $ab->f("id")) . " </td>\n"; } if ($page == 1) { echo '<td>' . mail_to($ab->f('email'), $ab->f('email')) . '</td>'; } if ($page == 2) { echo "<td>" . mail_to(empty_to_stripe($GO_USERS->f("email"))) . " </td>\n"; } break; case 'sex': echo '<td nowrap> ' . $strSexes[$ab->f('sex')] . ' </td>'; break; case 'birthday': case 'relation_date': $day = $ab->f($order[$i]) > 0 ? db_date_to_date($ab->f($order[$i])) : ''; echo '<td nowrap> ' . empty_to_stripe($day) . ' </td>'; break; case 'company_id': case 'parent': $db->query("SELECT name FROM ab_companies WHERE id = '" . (int) $ab->f($order[$i]) . "'"); echo '<td nowrap> ' . htmlspecialchars(empty_to_stripe($db->next_record() ? $db->f('name') : '')) . ' </td>'; break; case '': break; default: echo "<td nowrap> " . htmlspecialchars(empty_to_stripe($ab->f($order[$i]))) . " </td>\n"; } } }