Check if the files exist. Display tick if they do and cross if not.
[moodle-linuxchix.git] / enrol / manual / enrol.html
blob6422df421bc43dfbc0f40cf1679d61989226808c
1 <?php
3 if ($course->password != '' and !(isguestuser() and !empty($USER->enrolkey[$course->id]))) { // password
5 print_box_start('generalbox centerpara');
6 echo '<p align="center">';
7 if ($teacher) {
8 $teachername = "<a href=\"../user/view.php?id=$teacher->id&course=".SITEID."\">".fullname($teacher)."</a>.";
9 } else {
10 $teachername = get_string('yourteacher', '', $course->teacher);
12 print_string('enrolmentkeyfrom', '', $teachername);
14 </p>
16 <p align="center"><?php if (! empty($this->errormsg)) {formerr($this->errormsg);} ?></p>
19 <form method="post" action="enrol.php">
20 <table align="center" width="100%">
21 <tr>
22 <td align="right"><?php print_string("enrolmentkey") ?>:</td>
23 <td>
24 <input type="password" name="password" size="20" value="<?php p($password) ?>" />
25 <input type="hidden" name="id" value="<?php p($course->id) ?>" />
26 <input type="hidden" name="enrol" value="manual" />
27 <input type="submit" value="<?php print_string("enrolme") ?>" />
28 </td>
29 </tr>
30 </table>
31 </form>
32 <br />
34 <div align="center">
35 <form action="<?php p($CFG->wwwroot)?>/index.php" method="post">
36 <input type="submit" value="<?php print_string("cancel") ?>" />
37 </form>
38 </div>
40 <?php
41 print_box_end();
45 if (isguestuser()) {
46 print_box_start('centerpara');
47 if (empty($CFG->loginhttps)) {
48 $loginurl = $CFG->wwwroot .'/login/index.php';
49 } else {
50 $wwwroot = str_replace('http:','https:', $CFG->wwwroot);
51 $loginurl = $wwwroot .'/login/index.php';
53 print_single_button($loginurl, null, get_string('login'));
54 print_box_end();