3 if ($course->password
!= '' and !(isguestuser() and !empty($USER->enrolkey
[$course->id
]))) { // password
5 print_box_start('generalbox centerpara');
6 echo '<p align="center">';
8 $teachername = "<a href=\"../user/view.php?id=$teacher->id&course=".SITEID
."\">".fullname($teacher)."</a>.";
10 $teachername = get_string('yourteacher', '', $course->teacher
);
12 print_string('enrolmentkeyfrom', '', $teachername);
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%">
22 <td align=
"right"><?php print_string("enrolmentkey") ?>:
</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
") ?>" />
35 <form action
="<?php p($CFG->wwwroot)?>/index.php" method
="post">
36 <input type
="submit" value
="<?php print_string("cancel
") ?>" />
46 print_box_start('centerpara');
47 if (empty($CFG->loginhttps
)) {
48 $loginurl = $CFG->wwwroot
.'/login/index.php';
50 $wwwroot = str_replace('http:','https:', $CFG->wwwroot
);
51 $loginurl = $wwwroot .'/login/index.php';
53 print_single_button($loginurl, null, get_string('login'));