Swordfox\RecaptchaMultiple\Forms\RecaptchaMultipleField
Synopsis
class RecaptchaMultipleField
extends FormField
{
- // members
- private static $site_key;
- private static $secret_key;
- private static $proxy_server;
- private static $proxy_auth;
- private static boolean $verify_ssl = true;
- private static string $default_theme = 'light';
- private static string $default_type = 'image';
- private static string $default_size = 'normal';
- private $_captchaTheme;
- private $_captchaType;
- private $_captchaSize;
- private $_captchaBadge;
- private $_captchaCallback;
- // methods
- public void __construct()
- public string Field()
- public bool validate()
- public RecaptchaMultipleField setTheme()
- public string getCaptchaTheme()
- public RecaptchaMultipleField setCaptchaType()
- public string getCaptchaType()
- public RecaptchaMultipleField setCaptchaSize()
- public string getCaptchaSize()
- public RecaptchaMultipleField setCaptchaBadge()
- public string getCaptchaBadge()
- public RecaptchaMultipleField setCallback()
- public string getCallback()
- public string getSiteKey()
- public string getFormID()
Hierarchy
Extends
- SilverStripe\Forms\FormField
Members
private
- $_captchaBadge
—
string
Captcha badge, currently options are bottomright, bottomleft and inline - $_captchaCallback
—
string
Captcha callback, user defined function - $_captchaSize
—
string
Captcha size, currently options are normal and compact - $_captchaTheme
—
string
Captcha theme, currently options are light and dark - $_captchaType
—
string
Captcha type, currently options are audio and image - $default_size
—
string
Captcha size, currently options are normal, compact and invisible - $default_theme
—
string
Captcha theme, currently options are light and dark - $default_type
—
string
Captcha type, currently options are audio and image -
$proxy_auth
CURL Proxy authentication -
$proxy_server
CURL Proxy Server location -
$secret_key
Recaptcha Secret Key -
$site_key
Recaptcha Site Key -
$verify_ssl
Verify SSL Certificates
Methods
public
- __construct() — Creates a new Recaptcha 2 field.
- Field() — Adds in the requirements for the field
- getCallback() — Gets the Badge position for this captcha
- getCaptchaBadge() — Gets the Badge position for this captcha
- getCaptchaSize() — Gets the size for this captcha
- getCaptchaTheme() — Gets the theme for this captcha
- getCaptchaType() — Gets the type for this captcha
- getFormID() — Gets the form's id
- getSiteKey() — Gets the site key configured via RecaptchaMultipleField.site_key this is used in the template
- setCallback() — Sets the callback function
- setCaptchaBadge() — Sets the badge position for this captcha
- setCaptchaSize() — Sets the size for this captcha
- setCaptchaType() — Sets the type for this captcha
- setTheme() — Sets the theme for this captcha
- validate() — Validates the captcha against the Recaptcha2 API