Alternc  3.2
Alternc logiel libre pour l'hébergement
 All Data Structures Namespaces Files Functions Variables Pages
hta_adduser.php
Go to the documentation of this file.
1 <?php
2 /*
3  $Id: hta_adduser.php,v 1.6 2006/01/12 01:10:48 anarcat Exp $
4  ----------------------------------------------------------------------
5  AlternC - Web Hosting System
6  Copyright (C) 2002 by the AlternC Development Team.
7  http://alternc.org/
8  ----------------------------------------------------------------------
9  Based on:
10  Valentin Lacambre's web hosting softwares: http://altern.org/
11  ----------------------------------------------------------------------
12  LICENSE
13 
14  This program is free software; you can redistribute it and/or
15  modify it under the terms of the GNU General Public License (GPL)
16  as published by the Free Software Foundation; either version 2
17  of the License, or (at your option) any later version.
18 
19  This program is distributed in the hope that it will be useful,
20  but WITHOUT ANY WARRANTY; without even the implied warranty of
21  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22  GNU General Public License for more details.
23 
24  To read the license please visit http://www.gnu.org/copyleft/gpl.html
25  ----------------------------------------------------------------------
26  Original Author of file: Franck Missoum, Benjamin Sonntag
27  Purpose of file: Add a username to a protected folder
28  ----------------------------------------------------------------------
29 */
30 require_once("../class/config.php");
31 include_once("head.php");
32 
33 $fields = array (
34  "dir" => array ("request", "string", ""),
35  "user" => array ("request", "string", ""),
36 );
38 
39 ?>
40 <h3><?php printf(_("Adding a username in %s"),$dir); ?></h3>
41 <?php
42  if (isset($error) && $error) {
43  echo "<p class=\"alert alert-danger\">$error</p>";
44  }
45 ?>
46 
47 <form method="post" action="hta_doadduser.php" name="main" id="main">
48 <table border="1" cellspacing="0" cellpadding="4" class='tedit'>
49  <tr>
50  <th><input type="hidden" name="dir" value="<?php ehe($dir); ?>" /><?php __("Folder"); ?></th>
51  <td><code><?php echo $dir; ?></code></td>
52  </tr>
53  <tr>
54  <th><label for="user"><?php __("Username"); ?></label></th>
55  <td><input type="text" class="int" name="user" id="user" value="<?php ehe($user); ?>" size="20" maxlength="64" /></td>
56  </tr>
57  <tr>
58  <th><label for="password"><?php __("Password"); ?></label></th>
59  <td><input type="password" class="int" name="password" id="password" value="" size="20" maxlength="64" /><?php display_div_generate_password(DEFAULT_PASS_SIZE,"#password","#passwordconf"); ?></td>
60  </tr>
61  <tr>
62  <th><label for="passwordconf"><?php __("Confirm password"); ?></label></th>
63  <td><input type="password" class="int" name="passwordconf" id="passwordconf" value="" size="20" maxlength="64" /></td>
64  </tr>
65 </table>
66 <br />
67 <input type="submit" class="inb" value="<?php __("Add this user"); ?>" />
68  <input type="button" class="inb" value="<?php __("Cancel"); ?>" onclick="document.location='hta_edit.php?dir=<?php echo urlencode($dir); ?>';" />
69 </form>
70 <script type="text/javascript">
71 document.forms['main'].user.focus();
72 </script>
73 <?php include_once("foot.php"); ?>