remove old readme
[atutor.git] / themes / default / users / profile.tmpl.php
1 <?php require(AT_INCLUDE_PATH.'header.inc.php'); ?>
2
3 <form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>" name="form">
4 <?php global $languageManager, $_config; ?>
5 <div class="input-form">
6         <fieldset class="group_form"><legend class="group_form"><?php echo _AT('required_information'); ?></legend>
7         <div class="row">
8                 <h3><?php echo _AT('required_information'); ?></h3>
9         </div>
10
11         <div class="row">
12                 <label for="login"><?php echo _AT('login_name'); ?></label><br />
13                                 <span id="login"><?php echo stripslashes(htmlspecialchars($_POST['login'])); ?></span>
14                                 <input name="member_id" type="hidden" value="<?php echo intval($_POST['member_id']); ?>" />
15                                 <input name="login" type="hidden" value="<?php echo stripslashes(htmlspecialchars($_POST['login'])); ?>" />
16         </div>
17         <div class="row">
18                 <?php echo _AT('email_address'); ?><br />
19                 <?php echo stripslashes(htmlspecialchars($_POST['email'])); ?>
20                 <input type="checkbox" id="priv" name="private_email" value="1" <?php if ($_POST['private_email']) { echo 'checked="checked"'; } ?> /><label for="priv"><?php echo _AT('keep_email_private');?></label>
21         </div>
22         <div class="row">
23                 <span class="required" title="<?php echo _AT('required_field'); ?>">*</span><label for="first_name"><?php echo _AT('first_name'); ?></label><br />
24                 <input id="first_name" name="first_name" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['first_name'])); ?>" />
25         </div>
26
27         <div class="row">
28                 <label for="second_name"><?php echo _AT('second_name'); ?></label><br />
29                 <input id="second_name" name="second_name" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['second_name'])); ?>" />
30         </div>
31
32         <div class="row">
33                 <span class="required" title="<?php echo _AT('required_field'); ?>">*</span><label for="last_name"><?php echo _AT('last_name'); ?></label><br />
34                 <input id="last_name" name="last_name" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['last_name'])); ?>" />
35         </div>
36         
37         <?php if (admin_authenticate(AT_ADMIN_PRIV_USERS, TRUE)): 
38                         if ($_POST['status'] == AT_STATUS_INSTRUCTOR) {
39                                 $inst = ' checked="checked"';
40                         } else if ($_POST['status'] == AT_STATUS_STUDENT) {
41                                 $stud = ' checked="checked"';
42                         }  else if ($_POST['status'] == AT_STATUS_DISABLED) {
43                                 $disa = ' checked="checked"';
44                         } else {
45                                 $uncon = ' checked="checked"';
46                         }?>
47                         <input type="hidden" name="id" value="<?php echo $_POST['member_id']; ?>" >
48                         <div class="row">
49                                 <span class="required" title="<?php echo _AT('required_field'); ?>">*</span><?php echo _AT('account_status'); ?><br />
50
51                                 <input type="radio" name="status" value="0" id="disa" <?php echo $disa; ?> /><label for="disa"><?php echo _AT('disabled'); ?></label>
52                                 <?php if (defined('AT_EMAIL_CONFIRMATION') && AT_EMAIL_CONFIRMATION): ?>
53                                         <input type="radio" name="status" value="1" id="uncon" <?php echo $uncon; ?> /><label for="uncon"><?php echo _AT('unconfirmed'); ?></label>
54                                 <?php endif; ?>
55
56                                 <input type="radio" name="status" value="2" id="stud" <?php echo $stud; ?> /><label for="stud"><?php echo _AT('student'); ?></label>
57
58                                 <input type="radio" name="status" value="3" id="inst" <?php echo $inst; ?> /><label for="inst"><?php echo _AT('instructor'); ?></label>
59
60                                 <input type="hidden" name="old_status" value="<?php echo $_POST['old_status']; ?>" />
61                         </div>
62         <?php endif; ?>
63         </fieldset>
64         <fieldset class="group_form"><legend class="group_form"><?php echo _AT('personal_information'); ?></legend>
65         <div class="row">
66                 <h3><?php echo _AT('personal_information').' ('._AT('optional').')'; ?></h3>
67         </div>
68
69         <?php if (admin_authenticate(AT_ADMIN_PRIV_USERS, TRUE) && defined('AT_MASTER_LIST') && AT_MASTER_LIST): ?>
70                 <div class="row">
71                         <label for="student_id"><?php echo _AT('student_id'); ?></label><br />
72                                 <input type="text" name="student_id" value="<?php echo $_POST['student_id']; ?>" size="20" /><br />
73                 </div>
74                 <div class="row">
75                         <label for="student_pin"><?php echo _AT('student_pin'); ?></label><br />
76                         <input id="student_pin" name="student_pin" type="password" size="15" maxlength="15" value="<?php echo stripslashes(htmlspecialchars($_POST['student_pin'])); ?>" /><br />
77                 </div>
78         <?php endif; ?>
79
80         <div class="row">
81                 <?php echo _AT('date_of_birth'); ?><br />
82                 <label for="year"><?php echo _AT('year'); ?>: </label><input id="year" class="formfield" name="year" type="text" size="4" maxlength="4" value="<?php echo $_POST['year']; ?>" />  <label for="month"><?php echo _AT('month'); ?>: </label><input id="month" class="formfield" name="month" type="text" size="2" maxlength="2" value="<?php echo $_POST['month']; ?>" /> <label for="day"><?php echo _AT('day'); ?>: </label><input id="day" class="formfield" name="day" type="text" size="2" maxlength="2" value="<?php echo $_POST['day']; ?>" />
83         </div>
84
85         <div class="row">
86                 <?php echo _AT('gender'); ?><br />
87                 <input type="radio" name="gender" id="m" value="m" <?php if ($_POST['gender'] == 'm') { echo 'checked="checked"'; } ?> /><label for="m"><?php echo _AT('male'); ?></label> <input type="radio" value="f" name="gender" id="f" <?php if ($_POST['gender'] == 'f') { echo 'checked="checked"'; } ?> /><label for="f"><?php echo _AT('female'); ?></label>  <input type="radio" value="n" name="gender" id="ns" <?php if (($_POST['gender'] == 'n') || ($_POST['gender'] == '')) { echo 'checked="checked"'; } ?> /><label for="ns"><?php echo _AT('not_specified'); ?></label>
88         </div>
89
90         <div class="row">
91                 <label for="address"><?php echo _AT('street_address'); ?></label><br />
92                 <input id="address" name="address" size="40" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['address'])); ?>" />
93         </div>
94
95         <div class="row">
96                 <label for="postal"><?php echo _AT('postal_code'); ?></label><br />
97                 <input id="postal" name="postal" size="7" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['postal'])); ?>" />
98         </div>
99
100         <div class="row">
101                 <label for="city"><?php echo _AT('city'); ?></label><br />
102                 <input id="city" name="city" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['city'])); ?>" />
103         </div>
104
105         <div class="row">
106                 <label for="province"><?php echo _AT('province'); ?></label><br />
107                 <input id="province" name="province" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['province'])); ?>" />
108         </div>
109
110         <div class="row">
111                 <label for="country"><?php echo _AT('country'); ?></label><br />
112                 <input id="country" name="country" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['country'])); ?>" />
113         </div>
114
115         <div class="row">
116                 <label for="phone"><?php echo _AT('phone'); ?></label><br />
117                 <input size="11" name="phone" type="text" value="<?php echo stripslashes(htmlspecialchars($_POST['phone'])); ?>" id="phone" />
118         </div>
119
120         <div class="row">
121                 <label for="website"><?php echo _AT('web_site'); ?></label><br />
122                 <input id="website" name="website" size="40" type="text" value="<?php if ($_POST['website'] == '') { echo 'http://'; } else { echo stripslashes(htmlspecialchars($_POST['website'])); } ?>" />
123         </div>
124         </fieldset>
125         <div class="row buttons">
126                 <input type="submit" name="submit" value=" <?php echo _AT('save'); ?> " accesskey="s" />
127                 <input type="submit" name="cancel" value=" <?php echo _AT('cancel'); ?> " />
128         </div>
129 </div>
130 </form>
131
132 <?php require(AT_INCLUDE_PATH.'footer.inc.php'); ?>