Ejemplo n.º 1
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * User creation form
 *
 * 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;
}
global $page;
dd_formo('title=Создать пользователя;');
$glist = security_groups();
$max_login_len = opt_get('max_user_login_len');
$max_name_len = opt_get('max_user_name_len');
$max_passwd_len = opt_get('max_user_passwd_len');
?>
<script language="JavaScript" type="text/javascript">
  var gDesc = new Array ();
<?php 
foreach ($glist as $k => $g) {
    ?>
  gDesc[<?php 
    echo $g['access'];
    ?>
]='<?php 
    echo addslashes($g['desc']);
Ejemplo n.º 2
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Setting creation form
 *
 * 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=Добавить опцию;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var section   = getElementById ('section').value;
    var name      = getElementById ('name').value;
    var ident     = getElementById ('ident').value;
    var classname = getElementById ('classname').value;

    if (qtrim (section) == '') {
      alert ('Имя секции не может быть пустым.');
      return false;
    }

    if (qtrim (name) == '') {
      alert ('Имя создаваемой опции не может быть пустым.');
Ejemplo n.º 3
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Content creation form generation script
 *
 * 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=Создать новый раздел;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var name   = getElementById ('name').value;
    var path   = getElementById ('path').value;
    var cclass = getElementById ('class').value;
    if (qtrim (name) == '') {
      alert ('Имя создаваемого рздела не может быть пустым.');
      return false;
    }

    if (qtrim (path) == '') {
      alert ('Имя виртуальной папки не может быть пустым.');
      return false;
    }
Ejemplo n.º 4
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Dataset creation form 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=Создать новый набор данных;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var name = getElementById ('name').value;

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

    frm.submit ();
  }
</script>

<form action=".?action=create" method="POST" onsubmit="check (this); return false;">
Ejemplo n.º 5
0
 function Editor_EditForm_CreateForm($formname = '')
 {
     if (!$this->GetAllowed('ADDINFO')) {
         return;
     }
     $id = $this->Editor_EditForm_CurCatId();
     $dataset = $this->GetCatDataset($id);
     $dataset->FreeValues();
     println('<script language="JavaScript" type="text/javascript">');
     println('  var initialized=false;');
     println('  function Init () {');
     println('    if (initialized) return;');
     print $dataset->BuildInitScript($formname);
     println('    intialized=true;');
     println('  }');
     println('</script>');
     dd_formo('title=Добавить элемент в этот подкаталог;onexpand=Init ();');
     $dataset->DrawEditorForm($formname, content_url_get_full(), false, 'Добавить');
     dd_formc();
 }
Ejemplo n.º 6
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Script for storage creation form generation
 *
 * 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=Создать новое хранилище данных;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var name = getElementById ('name').value;
    var path = getElementById ('path').value;

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

    if (!checkDir ('/'+path)) {
      alert ('Указан некорректный путь. В названиях каталогов могут быть лишь буквы латинского алфавита и цифры.');
      return false;
    }
Ejemplo n.º 7
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;
    }
Ejemplo n.º 8
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Group creation form
 *
 * 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=Создать новую группу;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var name = getElementById ('name').value;
    if (qtrim (name) == '') {
      alert ('Имя создаваемой группы не может быть пустым.');
      return false;
    }
    frm.submit ();
  }
</script>

<form action=".?action=create" method="POST" onsubmit="check (this); return false;">
  Имя группы:
  <input type="text" id="name" name="name" value="<?php 
Ejemplo n.º 9
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Template creation form 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=Создать новый шаблон;');
?>
<script language="JavaScript" type="text/javascript">
  function check (frm) {
    var name = getElementById ('name').value;

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

    frm.submit ();
  }
</script>

<form action=".?action=create" method="post" onsubmit="check (this); return false;">
Ejemplo n.º 10
0
/**
 * Gate - Wiki engine and web-interface for WebTester Server
 *
 * Script for generation form for appending field to dataset
 *
 * 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;
}
global $id;
dd_formo('title=Добавить поле в набор данных;');
?>
<script language="JavaScript" type="text/javascript">
  function appcheck (frm) {
    var ftitle   = getElementById ('ftitle').value;
    var field    = getElementById ('field').value;
    var datatype = getElementById ('datatype').value;

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

    if (!isalphanum (field)) {
      alert ('Название поля может содержать лишь символы латинского алфавита и цифры.');
      return false;