メインコンテンツまでスキップ
Version: Fegg 5.x(開発版)

Turnstile::__construct

Set the Turnstile secret key

Description​

public Turnstile::__construct( string $secret )

Arguments​

NameData typeDefaultRemarks
$secretstringTurnstile secret key. Read it from site/config/env.php with feggEnv('FEGG_TURNSTILE_SECRET')

Example​

Controller
use Fegg\Captcha\Turnstile;

$turnstile = new Turnstile(feggEnv('FEGG_TURNSTILE_SECRET', ''));