Example #1
0
function call_service($service)
{
    if (file_exists('services/' . $service . '.php')) {
        include_once 'services/' . $service . '.php';
    } else {
        header("Content-Type: text/plain");
        echo "ERROR: Service {$service} unknown\n";
        getHelp();
        exit;
    }
    if (isset($_GET['info'])) {
        header("Content-Type: text/plain");
        if (function_exists($service . '_info')) {
            call_user_func($service . '_info');
        } else {
            echo "No information available for {$service}\n";
        }
        exit;
    }
    if (function_exists($service . '_main')) {
        call_user_func($service . '_main');
    } else {
        echo "ERROR: No main hook for {$service}\n";
    }
}
Example #2
0
            }
        }
        $ret_ar[] = $cur_file;
    }
    closedir($dh);
    natcasesort($ret_ar);
    return $ret_ar;
}
/**
 * Main Flow Starts Here
 */
if ($argc !== 2) {
    die(getHelp() . "\n");
}
if (!is_dir($argv[1])) {
    die(getHelp() . "\n");
}
$dir = $argv[1];
$allFiles = getFileList($dir);
if (!is_array($allFiles) or count($allFiles) < 1) {
    die('no files located' . "\n");
}
// tracking
$convertedFiles = array();
$errorFiles = array();
while (count($allFiles) > 0) {
    $file = array_shift($allFiles);
    $rc = der2Pem($file);
    if ($rc === true) {
        $convertedFiles[] = $file;
    } else {
Example #3
0
            }
            if ($_POST['status'] == 'no_approved') {
                $status = 'rejected';
            }
            Planner::set_approval_result($remainder_user_id, $_POST['plan_id'], $status, $_POST['comment']);
            echo '{"response":"1"}';
            exit;
        }
        if ($_POST['ajax_reminder'] == "window_set_minimize") {
            // при клике менеджером на кнопку "СВЕРНУТЬ ОКНО"
            Planner::window_set_minimize($_POST['client_id'], $_POST['window_type'], $_POST['event_type'], $_POST['window_set_minimize']);
            exit;
        }
        if ($_POST['ajax_reminder'] == "show_help") {
            // при клике менеджером на кнопку "?"
            echo getHelp('warnings.planner.terms');
            exit;
        }
        if ($_POST['ajax_reminder'] == "session_was_shown") {
            // отправляется клиентом когда очередная сессия оповещений была показа первый раз
            // яваскрипт отправляет запрос после того как были выгруженны окна оповещений
            // здесь в любом случае передаем id реального юзера (да же если админом в другом месте используется фейковый id для отладки)
            Planner::remaind_counter($_SESSION['access']['user_id']);
            exit;
        }
    }
}
if (isset($_GET['add_data_to_rt_from_basket'])) {
    include_once ROOT . '/libs/php/classes/rt_class.php';
    //echo $_GET['client_data'].' - '.$_GET['manager_login'];
    echo RT::add_data_from_basket_directly($_GET['client_data'], $_GET['dop_info'], $_GET['manager_login']);
Example #4
0
<?php

    // ** БЕЗОПАСНОСТЬ **
	// проверяем выдан ли доступ на вход на эту страницу
	// если нет $ACCESS['название раздела']['access'] или она равна FALSE прерываем работу скирпта 
	if(!@$ACCESS['default']['access']) exit($ACCESS_NOTICE);
	// ** БЕЗОПАСНОСТЬ **
 
    if(isset($_GET['help'])){
	   echo getHelp($_GET['help']);
	   exit;
	}
    if(isset($_GET['show_calculator'])){
	   include('./skins/tpl/calculators/calculators.tpl');
	   exit;
	}
	
	// временное перенаправление, НЕ ПОДНИМАТЬ ВЫШЕ ВПЕРЕДИ СТОЯЩИХ ИНСТРУКЦИЙ
	header('Location:?'.addOrReplaceGetOnURL('page=cabinet&section=requests&subsection=no_worcked_men',''));
    exit;
	
	
    echo '<div style="margin-top:300px;text-align:center;">такого раздела не существует</div>';
?>
<?php

require_once __DIR__ . '/vendor/autoload.php';
if ($argc != 3) {
    echo getHelp($argv);
    die;
}
$day = $argv[1];
$puzzle = $argv[2];
$day = ucfirst(strtolower($day));
$puzzle = ucfirst(strtolower($puzzle));
$class = "\\{$day}\\{$puzzle}";
$runner = new $class();
$runner();
function getHelp($argv)
{
    $progName = $argv[0];
    return <<<EOHELP
php {$progName} DayN PuzzleN
EOHELP;
}
Example #6
0
<?php 
}
?>
</head>

<body>
<center>
<table border="0" width="700">

<tr><td class="header" valign="bottom"><br /><br />&nbsp;<b>P<font color="red">o</font><font color="blue">o</font>kMail.com</b></td></tr>
<tr><td class="headerNav" valign="bottom"></td></tr>

<tr><td align="center" height="400px">

<b>Uppps!!!</b> <?php 
echo getHelp('404');
?>
 <a href="http://www.pookmail.com">P<font color="red">o</font><font color="blue">o</font>kMail.com</a>.

</td></tr>

<tr><td class="footer" align="left" valign="bottom">Copyright (c) pookmail.com 2004-<?php 
echo date('Y');
?>
</td></tr>

</table>

</center>
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
Example #7
0
</head>

<body>
<center>
<table border="0" width="700">

<tr><td class="header" valign="bottom"><br /><br />&nbsp;<b>P<font color="red">o</font><font color="blue">o</font>kMail.com</b></td></tr>
<tr><td class="headerNav" valign="bottom"></td></tr>

<tr><td align="center" height="400px">

<b><?php 
echo getLabel('sorry');
?>
</b>, <?php 
echo getHelp('500');
?>
.
<p />
<?php 
echo getLabel('please');
?>
, <?php 
echo getLabel('doclick');
?>
 <a href="javascript:history.go(-1)"><?php 
echo getLabel('here');
?>
</a> <?php 
echo getLabel('toretry');
?>
Example #8
0
        ?>
</a>
:
<a title="<?php 
        echo getHelp('viewMail');
        ?>
" href="<?php 
        echo '/mailbox/' . $e['id'] . '.eml?mode=view';
        ?>
"><?php 
        echo strtolower(getLabel('viewRawmail'));
        ?>
</a>
:
<a title="<?php 
        echo getHelp('deleteMail');
        ?>
" class="delete" href="<?php 
        echo '/mailbox.php?cmd=delete&id=' . $e['id'];
        ?>
"><?php 
        echo strtoupper(getLabel('delete'));
        ?>
</a>
<?php 
    }
    // end if proteccion
    ?>
</div>
<b><?php 
    echo getLabel('date');
Example #9
0
            }
        } elseif ($f->isDir()) {
            $b = copyDir($f->getRealPath(), $des . DIRECTORY_SEPARATOR . $d);
            if ($b !== 0) {
                return $b;
            }
        }
    }
    return 0;
}
$opt = parseOption();
if (isset($opt['v']) || isset($opt['version'])) {
    echo getVersion();
    exit;
} elseif (isset($opt['h']) || isset($opt['help'])) {
    echo getHelp();
    exit;
}
// install directory
$dir = getcwd();
if (isset($opt['d'])) {
    $dir = $opt['d'];
} elseif (isset($opt['dir'])) {
    $dir = $opt['dir'];
}
$dir = realpath(rtrim($dir, DIRECTORY_SEPARATOR));
// clean dir
if (isset($opt['clean'])) {
    clean($dir);
}
if (isset($opt['clear-cache'])) {