Merge branch 'MDL-53368-master-3' of https://github.com/HuongNV13/moodle

This commit is contained in:
Jun Pataleta 2023-08-24 22:51:26 +08:00
commit 29ec472284
No known key found for this signature in database
GPG key ID: F83510526D99E2C7
11 changed files with 157 additions and 6 deletions

View file

@ -77,6 +77,15 @@ class block_login extends block_base {
$this->content->text .= ' class="form-control" value="" autocomplete="current-password"/>';
$this->content->text .= '</div>';
// ReCaptcha.
if (login_captcha_enabled()) {
require_once($CFG->libdir . '/recaptchalib_v2.php');
$this->content->text .= '<div class="form-group">';
$this->content->text .= recaptcha_get_challenge_html(RECAPTCHA_API_URL, $CFG->recaptchapublickey,
current_language(), true);
$this->content->text .= '</div>';
}
$this->content->text .= '<div class="form-group">';
$this->content->text .= '<input type="submit" class="btn btn-primary btn-block" value="'.get_string('login').'" />';
$this->content->text .= '</div>';