コード例 #1
0
ファイル: menu_session.php プロジェクト: jhbsz/ossimTest
    }
}
?>
</select>
<?php 
require_once 'ossim_conf.inc';
$conf = $GLOBALS["CONF"];
if (preg_match('/\\d+\\.\\d+\\.\\d+\\.\\d+/', $sensor)) {
    //if (!$conf->get_conf("use_ntop_rewrite")) {
    //    $ntop_link = "$proto://$sensor:$port";
    //} else { //if use_ntop_rewrite is enabled
    //    $protocol = "http";
    //    if (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == "on") $protocol = "https";
    //    $ntop_link = "$protocol://" . $_SERVER['SERVER_NAME'] . "/ntop_$sensor";
    //}
    $ntop_links = Sensor::get_ntop_link($sensor);
    $ntop_link = $ntop_links["ntop"];
    $ntop_link = preg_replace("/\\/\$/", "", $ntop_link);
    ?>
<a href="<?php 
    echo $ntop_link;
    ?>
/NetNetstat.html"
       target="ntop">
       <?php 
    echo gettext("Reload");
    ?>
 </a>
<?php 
} else {
    if ($net_list = Net::get_list($conn, "name = '{$sensor}'")) {
コード例 #2
0
ファイル: rrd_global.php プロジェクト: jhbsz/ossimTest
{
    global $acid_link;
    global $acid_prefix;
    if ($val - $max > 0) {
        echo "<a href=\"" . Util::get_acid_info($ip, $acid_link, $acid_prefix) . "\"><font color=\"#991e1e\">{$val}</font></a>/" . "<a href=\"{$image}\">" . intval($val * 100 / $max) . "</a>%";
    } else {
        echo "<a href=\"" . Util::get_acid_info($ip, $acid_link, $acid_prefix) . "\">{$val}</a>/" . "<a href=\"{$image}\">" . intval($val * 100 / $max) . "</a>%";
    }
}
/* get conf */
$conf = $GLOBALS["CONF"];
$graph_link = $conf->get_conf("graph_link");
$acid_link = $conf->get_conf("acid_link");
$acid_prefix = $conf->get_conf("event_viewer");
//$ntop_link = $conf->get_conf("ntop_link");
$ntop_links = Sensor::get_ntop_link("127.0.0.1");
$ntop_link = $ntop_links["ntop"];
$ntop_link = preg_replace("/\\/\$/", "", $ntop_link);
$nagios_link = $conf->get_conf("nagios_link");
/* connect to db */
$db = new ossim_db();
$conn = $db->connect();
?>

<body>

    <table align="center" width="100%">
    <tr>
    <th colspan=8><?php 
echo gettext("RRD global anomalies");
?>