MediaWiki
REL1_34
HCaptchaAuthenticationRequest.php
Go to the documentation of this file.
1
<?php
2
3
namespace
MediaWiki\Extensions\ConfirmEdit\hCaptcha
;
4
5
use
CaptchaAuthenticationRequest
;
6
use
MediaWiki\Auth\AuthenticationRequest
;
7
8
class
HCaptchaAuthenticationRequest
extends
CaptchaAuthenticationRequest
{
9
public
function
__construct
() {
10
parent::__construct(
''
, [] );
11
}
12
16
public
function
loadFromSubmission
( array $data ) {
17
// unhack the hack in parent
18
return
AuthenticationRequest::loadFromSubmission( $data );
19
}
20
24
public
function
getFieldInfo
() {
25
$fieldInfo = parent::getFieldInfo();
26
27
return
[
28
'captchaWord'
=> [
29
'type'
=>
'string'
,
30
'label'
=> $fieldInfo[
'captchaInfo'
][
'label'
],
31
'help'
=> \wfMessage(
'hcaptcha-help'
),
32
],
33
];
34
}
35
}
CaptchaAuthenticationRequest
Generic captcha authentication request class.
Definition
CaptchaAuthenticationRequest.php:10
MediaWiki\Auth\AuthenticationRequest
This is a value object for authentication requests.
Definition
AuthenticationRequest.php:37
MediaWiki\Extensions\ConfirmEdit\hCaptcha\HCaptchaAuthenticationRequest
Definition
HCaptchaAuthenticationRequest.php:8
MediaWiki\Extensions\ConfirmEdit\hCaptcha\HCaptchaAuthenticationRequest\getFieldInfo
getFieldInfo()
Fetch input field info.The field info is an associative array mapping field names to info arrays....
Definition
HCaptchaAuthenticationRequest.php:24
MediaWiki\Extensions\ConfirmEdit\hCaptcha\HCaptchaAuthenticationRequest\loadFromSubmission
loadFromSubmission(array $data)
Initialize form submitted form data.The default behavior is to to check for each key of self::getFiel...
Definition
HCaptchaAuthenticationRequest.php:16
MediaWiki\Extensions\ConfirmEdit\hCaptcha\HCaptchaAuthenticationRequest\__construct
__construct()
Definition
HCaptchaAuthenticationRequest.php:9
MediaWiki\Extensions\ConfirmEdit\hCaptcha
Definition
HCaptcha.php:3
extensions
ConfirmEdit
hCaptcha
includes
HCaptchaAuthenticationRequest.php
Generated on Mon Nov 25 2024 16:04:35 for MediaWiki by
1.10.0