Your IP : 216.73.217.64


Current Path : /home3/gp97/docs.sapat20172020.97gp.net/php/
Upload File :
Current File : //home3/gp97/docs.sapat20172020.97gp.net/php/users_add.php

<?php
/* *************************************************
 *
 * Document Manager (C) 2002-2010
 * Version 4 - dmanager MySQL
 * Benjamin Sonntag <benjamin@sonntag.fr>
 * Chantal Bernard-Putz <chantal@bernard-putz.net>
 * Franck Denis
 * This software is protected by copyright laws,
 * please read the file COPYRIGHT
 * This software is provided as is with no warranty.
 *
 ************************************************* */


/* $Id: users_add.php 54 2011-06-29 10:30:14Z benjamin $ */

$admin = 1;

require_once("common.php");

$fields = array (
	"loginForm"       => array ("post", "string", ""),
	"passForm"        => array ("post", "string", ""),
	"email"       => array ("post", "string", ""),
	"r5"          => array ("post", "integer", 0),
	"r6"          => array ("post", "integer", 0),
	"drights"     => array ("post", "integer", 0),
	"druser"      => array ("post", "integer", 0),
	"createone"   => array ("post", "string", ""),
	"createmany"  => array ("post", "string", ""),
);

getFields($fields);

$title = _l("Users managment");

require_once("head.php");

?>
<p style="display: inline"><br /></p>
<h1><?php __l("Add a user") ?></h1>
<?php if (!empty($error)) { echo "<p class=\"error\">" . $error . "</p>"; } ?>
<form method="post" action="users_doadd.php">
<div id="formUser">
<table cellpadding="4" cellspacing="0" border="1" class="center">
	<tr>
		<th><label for="login"><?php __l("Login") ?></label></th>
		<td><input class="int" type="text" id="loginForm" name="loginForm" value="<?php echo $loginForm; ?>" size="20" maxlength="128" /></td>
	</tr>
	<tr>
		<th><label for="pass"><?php __l("Password") ?></label></th>
		<td><input class="int" type="password" id="passForm" name="passForm" value="" size="20" maxlength="128" /></td>
	</tr>
	<tr>
		<th><label for="email"><?php __l("Email") ?></label></th>
		<td><input class="int" type="text" id="email" name="email" value="<?php echo $email; ?>" size="30" maxlength="128" /></td>
	</tr>
	<tr>
		<th rowspan="2"><?php __l("Rights"); ?></th>
		<td><input class="inc" id="chkadmin" type="checkbox" name="r5" value="1"<?php echo ($r5 == "1" ? " checked=\"checked\"" : ""); ?> /><label for="chkadmin"><?php __l("Administrate users") ?></label></td>
	</tr>
	<tr>
	<td><input class="inc" id="chkpass" type="checkbox" name="r6" value="1"<?php echo ($r6 == "1" ? " checked=\"checked\"" : ""); ?> /><label for="chkpass"><?php __l("Can change password") ?></label></td>
	</tr>
	<tr>
		<th><label for="drights"><?php __l("Default rights on folders") ?></label></th>
		<td>
			<select id="drights" name="drights" class="int">
				<option value="0"><?php __l("No rights at all") ?></option>
				<option value="1"<?php echo ($drights == "1" ? " selected=\"selected\"" : "") ?>><?php __l("Read everywhere") ?></option>
				<option value="2"<?php echo ($drights == "2" ? " selected=\"selected\"" : "") ?>><?php __l("Write everywhere") ?></option>
				<option value="3"<?php echo ($drights == "3" ? " selected=\"selected\"" : "") ?>><?php __l("Same as this user:") ?></option>
			</select><br />
			<?php __l("User:"); ?>
			<select name="druser" size="1" class="int" style="margin-top: 2px;">
				<option value="0">-- Choisir --</option>
				<?php $doc->listUsersOptions(); ?>
			</select>
		</td>
	</tr>
	<tr>
		<td colspan="3" class="center"><input type="submit" class="inb" name="createone" value="<?php __l("Create this user") ?>" /> - <input type="submit" class="inb" name="createmany" value="<?php __l("Create this user then another") ?>" /></td>
	</tr>
</table>
</div>
</form>
<p style="display: inline"><br /></p>
<table style="width: 70%" cellpadding="1" cellspacing="0" class="center">
	<tr>
		<td class="center"><img class="vmiddle noborder" src="<?php echo $pngPath; ?>users.png" alt="<?php __l("User Administration") ?>" />&nbsp;<a href="users_admin.php"><?php __l("User Administration") ?></a></td>
		<td class="center"><img class="vmiddle noborder" src="<?php echo $pngPath; ?>folder.png" alt="<?php __l("Back to the Document Manager") ?>" />&nbsp;<a href="browser.php"><?php __l("Back to the Document Manager") ?></a></td>
	</tr>
</table>
<?php require_once ("foot.php"); ?>