[ Index ] |
PHP Cross Reference of phpBB-3.3.14-deutsch |
[Source view] [Print] [Project Stats]
This is a PHP library that handles calling reCAPTCHA. BSD 3-Clause License
Copyright: | (c) 2019, Google Inc. |
File Size: | 269 lines (9 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
ReCaptcha:: (7 methods):
__construct()
verify()
setExpectedHostname()
setExpectedApkPackageName()
setExpectedAction()
setScoreThreshold()
setChallengeTimeout()
__construct($secret, RequestMethod $requestMethod = null) X-Ref |
Create a configured instance to use the reCAPTCHA service. param: string $secret The shared key between your site and reCAPTCHA. param: RequestMethod $requestMethod method used to send the request. Defaults to POST. |
verify($response, $remoteIp = null) X-Ref |
Calls the reCAPTCHA siteverify API to verify whether the user passes CAPTCHA test and additionally runs any specified additional checks param: string $response The user response token provided by reCAPTCHA, verifying the user on your site. param: string $remoteIp The end user's IP address. return: Response Response from the service. |
setExpectedHostname($hostname) X-Ref |
Provide a hostname to match against in verify() This should be without a protocol or trailing slash, e.g. www.google.com param: string $hostname Expected hostname return: ReCaptcha Current instance for fluent interface |
setExpectedApkPackageName($apkPackageName) X-Ref |
Provide an APK package name to match against in verify() param: string $apkPackageName Expected APK package name return: ReCaptcha Current instance for fluent interface |
setExpectedAction($action) X-Ref |
Provide an action to match against in verify() This should be set per page. param: string $action Expected action return: ReCaptcha Current instance for fluent interface |
setScoreThreshold($threshold) X-Ref |
Provide a threshold to meet or exceed in verify() Threshold should be a float between 0 and 1 which will be tested as response >= threshold. param: float $threshold Expected threshold return: ReCaptcha Current instance for fluent interface |
setChallengeTimeout($timeoutSeconds) X-Ref |
Provide a timeout in seconds to test against the challenge timestamp in verify() param: int $timeoutSeconds Expected hostname return: ReCaptcha Current instance for fluent interface |
Generated: Mon Nov 25 19:05:08 2024 | Cross-referenced by PHPXref 0.7.1 |