Download the PHP package aryehraber/statamic-recaptcha without Composer

On this page you can find all versions of the php package aryehraber/statamic-recaptcha. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package statamic-recaptcha

For Statamic V3, please use the new Captcha addon: https://github.com/aryehraber/statamic-captcha


Recaptcha (Statamic V2)

Protect your Statamic forms using reCAPTCHA or hCaptcha.

This addon allows you to protect your Statamic forms from spam and abuse using reCAPTCHA or hCaptcha service.

After the initial setup, all you need to do is add the {{ recaptcha }} tag inside your forms, easy peasy!

reCAPTCHA

Setup

  1. Firstly, copy the Recaptcha folder into site/addons/.

  2. Next, you'll have to add reCAPTCHA's API script to your site's <head> using {{ recaptcha:head }}. You may also want to look into Statamic's Yield & Section tags to only render the script when needed.

  3. Then configure which forms will be using Recaptcha via the settings in the CP (Configure > Addons > Recaptcha). Here you can also customise the error message shown when validation fails, as well as various other settings.

  4. Finally, head over to https://www.google.com/recaptcha/admin, or https://dashboard.hcaptcha.com to create your SITE_KEY & SECRET and add them to Recaptcha's settings. Alternatively, add them to the site's .env file using RECAPTCHA_SITE_KEY & RECAPTCHA_SECRET. Please note: Recaptcha's Addon settings will take precedence over the .env settings.

Usage

This will automatically render the reCAPTCHA element on the page (if a valid SITE_KEY was found). After the form is submitted, the Addon will temporarily halt the form from saving while the submission is verified. If all is good, the form will save as normal, otherwise an error will be added to the {{ errors }} array (together with any other errors, if they exist) which you can handle the same way as you would normally.

hCaptcha

As of v2.7.0, this Addon also supports hCaptcha! Simply switch the Captcha Service setting to hCaptcha inside of Configure > Addons > Recaptcha and update the API keys to your hCaptcha keys.

User Registration

As of v2.8.0, Recaptcha can verify user registration submissions from Statamic's {{ user:register_form }} form. Activate the feature inside Configure > Addons > Recaptcha and follow the same usage instructions as above.

Invisible Recaptcha

As of v2.0, Recaptcha also supports the Invisible reCAPTCHA:

  1. Simply turn on the Invisible toggle in Recaptcha's settings.
  2. Turn on Hide Badge to hide Recaptcha badge
  3. Add required Google Terms and Privacy Policy using {{ recaptcha:disclaimer }}

All versions of statamic-recaptcha with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package aryehraber/statamic-recaptcha contains the following files

Loading the files please wait ...