\Vigas\Application\ControllerCaptcha

Class Captcha.

Manages Google reCAPTCHA

Summary

Methods
Properties
Constants
__construct()
validCaptcha()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$siteKey
$secretKey
$captcha_response
$remote_ip
$api_url
N/A

Properties

$siteKey

$siteKey : string

Type

string — reCAPTCHA site key

$secretKey

$secretKey : string

Type

string — reCAPTCHA secret key

$captcha_response

$captcha_response : string

Type

string — reCAPTCHA response

$remote_ip

$remote_ip : string

Type

string — user's IP address

$api_url

$api_url : string

Type

string — Google reCAPTCHA url

Methods

__construct()

__construct(string  $siteKey, string  $secretKey, string  $captcha_response, string  $remote_ip) 

Parameters

string $siteKey

reCAPTCHA site key

string $secretKey

reCAPTCHA secret key

string $captcha_response

reCAPTCHA response

string $remote_ip

user IP address

validCaptcha()

validCaptcha() : boolean

Returns

boolean —

Returns true if captcha is validated, false otherwise