} else { $table = new CTableInfo(S_NO_MEDIA_TYPES_DEFINED); $table->setHeader(array(make_sorting_link(S_TYPE, 'mt.type'), make_sorting_link(S_DESCRIPTION, 'mt.description'), S_DETAILS)); $result = DBselect('SELECT mt.* ' . ' FROM media_type mt' . ' WHERE ' . DBin_node('mt.mediatypeid') . order_by('mt.type,mt.description')); while ($row = DBfetch($result)) { switch ($row['type']) { case MEDIA_TYPE_EMAIL: $details = S_SMTP_SERVER . ": '" . $row['smtp_server'] . "', " . S_SMTP_HELO . ": '" . $row['smtp_helo'] . "', " . S_SMTP_EMAIL . ": '" . $row['smtp_email'] . "'"; break; case MEDIA_TYPE_EXEC: $details = S_SCRIPT_NAME . ": '" . $row['exec_path'] . "'"; break; case MEDIA_TYPE_SMS: $details = S_GSM_MODEM . ": '" . $row['gsm_modem'] . "'"; break; case MEDIA_TYPE_JABBER: $details = S_JABBER_IDENTIFIER . ": '" . $row['username'] . "'"; break; default: $details = ''; } $table->addRow(array(media_type2str($row['type']), new CLink($row["description"], "?&form=update&mediatypeid=" . $row["mediatypeid"], 'action'), $details)); $row_count++; } $table->show(); } zbx_add_post_js('insert_in_element("numrows","' . $row_count . '");'); ?> <?php include_once "include/page_footer.php";
} if ($header_host['available'] == HOST_AVAILABLE_TRUE) { $available = new CSpan(S_AVAILABLE, 'off'); } else { if ($header_host['available'] == HOST_AVAILABLE_FALSE) { $available = new CSpan(S_NOT_AVAILABLE, 'on'); } else { if ($header_host['available'] == HOST_AVAILABLE_UNKNOWN) { $available = new CSpan(S_UNKNOWN, 'unknown'); } } } $tbl_header_host = new CTableInfo(); $tbl_header_host->addRow(array(new CLink(bold(S_HOST_LIST), 'hosts.php?hostid=' . $header_host['hostid'] . url_param('groupid')), $description, $items, $graphs, array(bold(S_DNS . ': '), $dns), array(bold(S_IP . ': '), $ip), array(bold(S_PORT . ': '), $port), array(bold(S_STATUS . ': '), $status), array(bold(S_AVAILABILITY . ': '), $available))); $tbl_header_host->setClass('infobox'); $tbl_header_host->show(); } // --->>> SELECTED HOST HEADER INFORMATION <<<--- $form = new CForm('triggers.php'); $form->setName('triggers'); $form->setMethod('post'); $form->addVar('hostid', $_REQUEST['hostid']); $table = new CTableInfo(S_NO_TRIGGERS_DEFINED); $table->setHeader(array(new CCheckBox('all_triggers', NULL, "checkAll('" . $form->GetName() . "','all_triggers','g_triggerid');"), make_sorting_link(S_SEVERITY, 't.priority'), make_sorting_link(S_STATUS, 't.status'), $_REQUEST['hostid'] > 0 ? NULL : make_sorting_link(S_HOST, 'h.host'), make_sorting_link(S_NAME, 't.description'), S_EXPRESSION, S_ERROR)); $options = array('select_hosts' => 1, 'editable' => 1, 'extendoutput' => 1); if ($showdisabled == 0) { $options += array('status' => TRIGGER_STATUS_ENABLED); } if ($PAGE_HOSTS['selected'] > 0) { $options += array('hostids' => $PAGE_HOSTS['selected']); } else {