Open Journal Systems  3.3.0
FormValidatorReCaptcha Class Reference
Inheritance diagram for FormValidatorReCaptcha:
FormValidator

Public Member Functions

 __construct (&$form, $userIp, $message, $hostname='')
 
 isValid ()
 
- Public Member Functions inherited from FormValidator
 __construct (&$form, $field, $type, $message, $validator=null)
 
 getField ()
 
 getFieldValue ()
 
getForm ()
 
 getMessage ()
 
 getType ()
 
getValidator ()
 
 isEmptyAndOptional ()
 

Data Fields

 $_hostname
 
 $_userIp
 
- Data Fields inherited from FormValidator
 $_field
 
 $_form
 
 $_message
 
 $_type
 
 $_validator
 

Detailed Description

Form validation check reCaptcha values.

Definition at line 20 of file FormValidatorReCaptcha.inc.php.

Constructor & Destructor Documentation

◆ __construct()

FormValidatorReCaptcha::__construct ( $form,
  $userIp,
  $message,
  $hostname = '' 
)

Constructor.

Parameters
$formobject
$userIpstring IP address of user request
$messagestring Key of message to display on mismatch
$hostnamestring Hostname to expect in validation response

Definition at line 39 of file FormValidatorReCaptcha.inc.php.

Member Function Documentation

◆ isValid()

FormValidatorReCaptcha::isValid ( )
See also
FormValidator::isValid() Determine whether or not the Form meets this ReCaptcha constraint.
Returns
boolean

Reimplemented from FormValidator.

Definition at line 54 of file FormValidatorReCaptcha.inc.php.

References FormValidator\getForm(), and Config\getVar().

Field Documentation

◆ $_hostname

string FormValidatorReCaptcha::$_hostname

The hostname to expect in the validation response

Definition at line 30 of file FormValidatorReCaptcha.inc.php.

◆ $_userIp

string FormValidatorReCaptcha::$_userIp

The initiating IP address of the user

Definition at line 25 of file FormValidatorReCaptcha.inc.php.


The documentation for this class was generated from the following file: