2 if ($show_instructions) {
3 $columns = 'twocolumns';
5 $columns = 'onecolumn';
8 if (empty($CFG->xmlstrictheaders
) and !empty($CFG->loginpasswordautocomplete
)) {
9 $autocomplete = 'autocomplete="off"';
14 <div class=
"loginbox clearfix <?php echo $columns ?>">
15 <div
class="loginpanel">
17 if (($CFG->registerauth
== 'email') ||
!empty($CFG->registerauth
)) { ?>
18 <div class=
"skiplinks"><a class=
"skip" href=
"signup.php"><?php print_string("tocreatenewaccount"); ?></a></div>
21 <h2><?php print_string("returningtosite") ?></h2>
22 <div class=
"subcontent loginsub">
25 print_string("loginusing");
27 echo '('.get_string("cookiesenabled").')';
28 echo $OUTPUT->help_icon('cookiesenabled');
32 if (!empty($errormsg)) {
33 echo '<div class="loginerrors">';
34 echo $OUTPUT->error_text($errormsg);
38 <form action=
"<?php echo $CFG->httpswwwroot; ?>/login/index.php" method
="post" id
="login" <?php
echo $autocomplete; ?> >
39 <div class=
"loginform">
40 <div class=
"form-label"><label for=
"username"><?php print_string("username") ?></label></div>
41 <div class=
"form-input">
42 <input type=
"text" name=
"username" id=
"username" size=
"15" value=
"<?php p($frm->username) ?>" />
44 <div
class="clearer"><!-- --></div
>
45 <div
class="form-label"><label
for="password"><?php
print_string("password") ?></label></div>
46 <div class=
"form-input">
47 <input type=
"password" name=
"password" id=
"password" size=
"15" value=
"" <?php echo $autocomplete; ?> />
48 <input type=
"submit" id=
"loginbtn" value=
"<?php print_string("login
") ?>" />
51 <div
class="clearer"><!-- --></div
>
52 <?php
if (isset($CFG->rememberusername
) and $CFG->rememberusername
== 2) { ?>
53 <div class=
"rememberpass">
54 <input type=
"checkbox" name=
"rememberusername" id=
"rememberusername" value=
"1" <?php if ($frm->username
) {echo 'checked="checked"';} ?> />
55 <label for=
"rememberusername"><?php print_string('rememberusername', 'admin') ?></label>
58 <div class=
"clearer"><!-- --></div>
59 <div class=
"forgetpass"><a href=
"forgot_password.php"><?php print_string("forgotten") ?></a></div>
63 <?php if ($CFG->guestloginbutton
and !isguestuser()) { ?>
64 <div class=
"subcontent guestsub">
66 <?php print_string("someallowguest") ?>
68 <form action=
"index.php" method=
"post" id=
"guestlogin">
69 <div class=
"guestform">
70 <input type=
"hidden" name=
"username" value=
"guest" />
71 <input type=
"hidden" name=
"password" value=
"guest" />
72 <input type=
"submit" value=
"<?php print_string("loginguest
") ?>" />
78 <?php if ($show_instructions) { ?>
79 <div class=
"signuppanel">
80 <h2><?php print_string("firsttime") ?></h2>
81 <div class=
"subcontent">
82 <?php if (is_enabled_auth('none')) { // instructions override the rest for security reasons
83 print_string("loginstepsnone");
84 } else if ($CFG->registerauth
== 'email') {
85 if (!empty($CFG->auth_instructions
)) {
86 echo format_text($CFG->auth_instructions
);
88 print_string("loginsteps", "", "signup.php");
90 <div class=
"signupform">
91 <form action=
"signup.php" method=
"get" id=
"signup">
92 <div><input type=
"submit" value=
"<?php print_string("startsignup
") ?>" /></div
>
95 <?php
} else if (!empty($CFG->registerauth
)) {
96 echo format_text($CFG->auth_instructions
); ?>
97 <div class=
"signupform">
98 <form action=
"signup.php" method=
"get" id=
"signup">
99 <div><input type=
"submit" value=
"<?php print_string("startsignup
") ?>" /></div
>
103 echo format_text($CFG->auth_instructions
);
108 <?php if (!empty($potentialidps)) { ?>
109 <div class=
"subcontent potentialidps">
110 <h6><?php print_string('potentialidps', 'auth'); ?></h6>
111 <div class=
"potentialidplist">
112 <?php foreach ($potentialidps as $idp) {
113 echo '<div class="potentialidp"><a href="' . $idp['url']->out() . '" title="' . $idp['name'] . '">' . $OUTPUT->render($idp['icon'], $idp['name']) . ' ' . $idp['name'] . '</a></div>';