| 1 |
<?php |
|---|
| 2 |
|
|---|
| 3 |
|
|---|
| 4 |
|
|---|
| 5 |
|
|---|
| 6 |
|
|---|
| 7 |
|
|---|
| 8 |
|
|---|
| 9 |
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 |
|
|---|
| 15 |
|
|---|
| 16 |
|
|---|
| 17 |
|
|---|
| 18 |
|
|---|
| 19 |
|
|---|
| 20 |
|
|---|
| 21 |
|
|---|
| 22 |
|
|---|
| 23 |
|
|---|
| 24 |
|
|---|
| 25 |
|
|---|
| 26 |
|
|---|
| 27 |
|
|---|
| 28 |
|
|---|
| 29 |
|
|---|
| 30 |
|
|---|
| 31 |
|
|---|
| 32 |
require_once("../class/config.php"); |
|---|
| 33 |
|
|---|
| 34 |
if (!$admin->enabled) { |
|---|
| 35 |
__("This page is restricted to authorized staff"); |
|---|
| 36 |
exit(); |
|---|
| 37 |
} |
|---|
| 38 |
|
|---|
| 39 |
if (!isset($canpass)) $canpass=1; |
|---|
| 40 |
|
|---|
| 41 |
include("head.php"); |
|---|
| 42 |
|
|---|
| 43 |
?> |
|---|
| 44 |
</head> |
|---|
| 45 |
<body> |
|---|
| 46 |
<h3><?php __("New member"); ?></h3> |
|---|
| 47 |
<?php |
|---|
| 48 |
if ($error) { |
|---|
| 49 |
echo "<p class=\"error\">$error</p>"; |
|---|
| 50 |
} |
|---|
| 51 |
?> |
|---|
| 52 |
<form method="post" action="adm_doadd.php"> |
|---|
| 53 |
<table border="1" cellspacing="0" cellpadding="4"> |
|---|
| 54 |
<tr><th><label for="login"><?php __("Username"); ?></label></th><td> |
|---|
| 55 |
<input type="text" class="int" name="login" id="login" value="<?php echo $login; ?>" size="20" maxlength="64" /> |
|---|
| 56 |
</td></tr> |
|---|
| 57 |
<tr> |
|---|
| 58 |
<th><label for="pass"><?php __("Initial password"); ?></label></th> |
|---|
| 59 |
<td><input type="password" id="pass" name="pass" class="int" value="<?php echo $pass; ?>" size="20" maxlength="64" /></td> |
|---|
| 60 |
</tr> |
|---|
| 61 |
<tr> |
|---|
| 62 |
<th><label for="passconf"><?php __("Confirm password"); ?></label></th> |
|---|
| 63 |
<td><input type="password" id="passconf" name="passconf" class="int" value="<?php echo $passconf; ?>" size="20" maxlength="64" /></td> |
|---|
| 64 |
</tr> |
|---|
| 65 |
<tr> |
|---|
| 66 |
<th><label for="canpass"><?php __("Can he change its password"); ?></label></th> |
|---|
| 67 |
<td><select class="inl" name="canpass" id="canpass"> |
|---|
| 68 |
<?php |
|---|
| 69 |
for($i=0;$i<count($bro->l_icons);$i++) { |
|---|
| 70 |
echo "<option"; |
|---|
| 71 |
if ($canpass==$i) echo " selected=\"selected\""; |
|---|
| 72 |
echo " value=\"$i\">"._($bro->l_icons[$i])."</option>"; |
|---|
| 73 |
} |
|---|
| 74 |
?></select> |
|---|
| 75 |
</td> |
|---|
| 76 |
</tr> |
|---|
| 77 |
<tr> |
|---|
| 78 |
<th><label for="nom"><?php echo _("Surname")."</label> / <label for=\"prenom\">"._("First Name"); ?></label></th> |
|---|
| 79 |
<td><input class="int" type="text" id="nom" name="nom" value="<?php echo $nom; ?>" size="20" maxlength="128" /> / <input type="text" name="prenom" id="prenom" value="<?php echo $prenom; ?>" class="int" size="20" maxlength="128" /></td> |
|---|
| 80 |
</tr> |
|---|
| 81 |
<tr> |
|---|
| 82 |
<th><label for="nmail"><?php __("Email address"); ?></label></th> |
|---|
| 83 |
<td><input type="text" name="nmail" id="nmail" class="int" value="<?php echo $nmail; ?>" size="30" maxlength="128" /></td> |
|---|
| 84 |
</tr> |
|---|
| 85 |
<tr> |
|---|
| 86 |
<th><label for="type"><?php __("Account type"); ?></label></th> |
|---|
| 87 |
<td><select name="type" id="type" class="inl"> |
|---|
| 88 |
<?php |
|---|
| 89 |
$db->query("SELECT distinct(type) FROM defquotas ORDER by type"); |
|---|
| 90 |
while($db->next_record()) { |
|---|
| 91 |
$type = $db->f("type"); |
|---|
| 92 |
echo "<option value=\"$type\""; |
|---|
| 93 |
if($type == 'default') |
|---|
| 94 |
echo " selected=\"selected\""; |
|---|
| 95 |
echo ">$type</option>"; |
|---|
| 96 |
} |
|---|
| 97 |
?></select> |
|---|
| 98 |
</td> |
|---|
| 99 |
</tr> |
|---|
| 100 |
|
|---|
| 101 |
<tr> |
|---|
| 102 |
<th colspan="2"> |
|---|
| 103 |
<input type="checkbox" name="create_dom" value="1" /> |
|---|
| 104 |
<label><?php printf(_("Create the domain <b>username.%s</b>"),""); ?></label> |
|---|
| 105 |
<select name="create_dom_list"> |
|---|
| 106 |
<?php if (variable_get('hosting_tld')) { ?> |
|---|
| 107 |
<option value="<?php echo variable_get('hosting_tld'); ?>" selected="selected"><?php echo variable_get('hosting_tld'); ?></option> |
|---|
| 108 |
<?php } |
|---|
| 109 |
|
|---|
| 110 |
$domain=$dom->enum_domains(); |
|---|
| 111 |
reset($domain); |
|---|
| 112 |
while (list($key,$val)=each($domain)) { ?> |
|---|
| 113 |
<option value="<?php echo $val; ?>" > <?php echo $val?> </option> |
|---|
| 114 |
<?php } ?> |
|---|
| 115 |
</select> |
|---|
| 116 |
</th> |
|---|
| 117 |
</tr> |
|---|
| 118 |
<tr> |
|---|
| 119 |
<td colspan="2"><input type="submit" class="inb" name="submit" value="<?php __("Create a new member"); ?>" /></td> |
|---|
| 120 |
</tr> |
|---|
| 121 |
</table> |
|---|
| 122 |
</form> |
|---|
| 123 |
|
|---|
| 124 |
</body> |
|---|
| 125 |
</html> |
|---|
| 126 |
|
|---|