Exemplo n.º 1
0
    return false;
}
$ruri = ltrim(substr($ruri, strlen($remove)), '/');
if (strpos($ruri, '?') === false) {
    $params = '';
    $path = $ruri;
} else {
    list($path, $params) = preg_split('/\\?/', $ruri, 2);
}
$special = array('css/icinga.css', 'css/icinga.min.css', 'js/icinga.dev.js', 'js/icinga.min.js');
if (in_array($path, $special)) {
    include_once __DIR__ . '/EmbeddedWeb.php';
    EmbeddedWeb::start();
    switch ($path) {
        case 'css/icinga.css':
            Stylesheet::send();
            exit;
        case 'css/icinga.min.css':
            Stylesheet::sendMinified();
            exit;
        case 'js/icinga.dev.js':
            JavaScript::send();
            exit;
        case 'js/icinga.min.js':
            JavaScript::sendMinified();
            break;
        default:
            return false;
    }
} elseif ($path === 'svg/chart.php') {
    if (!array_key_exists('data', $_GET)) {
Exemplo n.º 2
0
if (strpos($ruri, '?') === false) {
    $params = '';
    $path = $ruri;
} else {
    list($path, $params) = preg_split('/\\?/', $ruri, 2);
}
$special = array('css/icinga.css', 'css/icinga.min.css', 'js/icinga.dev.js', 'js/icinga.ie8.js', 'js/icinga.min.js');
if (in_array($path, $special)) {
    include_once __DIR__ . '/EmbeddedWeb.php';
    EmbeddedWeb::start();
    switch ($path) {
        case 'css/icinga.css':
            Stylesheet::send();
            exit;
        case 'css/icinga.min.css':
            Stylesheet::send(true);
            exit;
        case 'js/icinga.dev.js':
            JavaScript::send();
            exit;
        case 'js/icinga.min.js':
            JavaScript::sendMinified();
            break;
        case 'js/icinga.ie8.js':
            JavaScript::sendForIe8();
            break;
        default:
            return false;
    }
} elseif ($path === 'svg/chart.php') {
    if (!array_key_exists('data', $_GET)) {