skillaug/re-captcha

reCaptcha 2.0

Maintainers

Package info

github.com/skillaug/re-captcha

Type:php

pkg:composer/skillaug/re-captcha

Statistics

Installs: 11

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.0.0 2018-06-23 05:16 UTC

This package is auto-updated.

Last update: 2026-03-14 17:13:17 UTC


README

Google reCaptcha 2.0 for PHP

Installation

composer require skillaug/re-captcha "1.0.0"

Usage

$secret = 'YOUR_SECRET';

$reCaptcha = new \skillaug\reCaptcha( $secret );

$response = $reCaptcha->verifyResponse(@$_POST["g-recaptcha-response"]);

if ( empty( $response ) || $response->success === false ) {
    die('invalid captcha');
}