Example #1
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Service creation for generator
 *
 * Copyright (c) 2008-2009 Sergey I. Sharybin <*****@*****.**>
 *
 * This program can be distributed under the terms of the GNU GPL.
 * See the file COPYING.
 */
if ($PHP_SELF != '') {
    print 'HACKERS?';
    die;
}
dd_formo('title=Создать новый сервис;');
$list = content_Registered_SClasses();
?>
<script language="JavaScript" type="text/javascript">
  var cur_service='<?php 
echo $list[0]['class'];
?>
';
  function check (frm) {
    var name = getElementById ('name').value;

    if (qtrim (name) == '') {
      alert ('Имя создаваемого сервиса не может быть пустым.');
      return false;
    }

    frm.submit ();
Example #2
0
 *
 * This program can be distributed under the terms of the GNU GPL.
 * See the file COPYING.
 */
if ($PHP_SELF != '') {
    print 'HACKERS?';
    die;
}
formo('title=Список существующих сервисов;');
?>
  <table class="list smb">
    <tr class="h"><th class="n first">№</th><th width="40%">Название</th><th>Базовый класс</th><th width="48" class="last">&nbsp;</th></tr>
<?php 
$n = count($list);
$titles = array();
$classes = content_Registered_SClasses();
for ($i = 0; $i < count($classes); $i++) {
    $titles[$classes[$i]['class']] = $classes[$i]['pseudonym'];
}
for ($i = 0; $i < $n; $i++) {
    $it = $list[$i];
    $className = $titles[$it['sclass']];
    $d = true;
    ?>
    <tr<?php 
    echo $i == $n - 1 ? ' class="last"' : '';
    ?>
><td class="n"><?php 
    echo $i + 1;
    ?>
.</td><td><a href=".?action=editor&id=<?php