Download the PHP package paragonie/recaptcha without Composer

On this page you can find all versions of the php package paragonie/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 recaptcha

PIE ReCAPTCHA

This is a fork of Google's PHP ReCAPTCHA client that allows you to pass cURL options, e.g. to proxy requests over Tor.

reCAPTCHA PHP client library

Build Status Latest Stable Version Total Downloads

Description

reCAPTCHA is a free CAPTCHA service that protect websites from spam and abuse. This is Google authored code that provides plugins for third-party integration with reCAPTCHA.

Installation

Composer (Recommended)

Composer is a widely used dependency manager for PHP packages. This reCAPTCHA client is available on Packagist as google/recaptcha and can be installed either by running the composer require command or adding the library to your composer.json. To enable Composer for you project, refer to the project's Getting Started documentation.

To add this dependency using the command, run the following from within your project directory:

Alternatively, add the dependency directly to your composer.json file:

Direct download (no Composer)

If you wish to install the library manually (i.e. without Composer), then you can use the links on the main project page to either clone the repo or download the ZIP file. For convenience, an autoloader script is provided in src/autoload.php which you can require into your script instead of Composer's vendor/autoload.php. For example:

The classes in the project are structured according to the PSR-4 standard, so you may of course also use your own autoloader or require the needed files directly in your code.

Development install

If you would like to contribute to this project or run the unit tests on within your own environment you will need to install the development dependencies, in this case that means PHPUnit. If you clone the repo and run composer install from within the repo, this will also grab PHPUnit and all its dependencies for you. If you only need the autoloader installed, then you can always specify to Composer not to run in development mode, e.g. composer install --no-dev.

Note: These dependencies are only required for development, there's no requirement for them to be included in your production code.

Usage

First, register keys for your site at https://www.google.com/recaptcha/admin

When your app receives a form submission containing the g-recaptcha-response field, you can verify it using:

You can see an end-to-end working example in examples/example-captcha.php

Upgrading

From 1.0.0

The previous version of this client is still available on the 1.0.0 tag in this repo but it is purely for reference and will not receive any updates.

The major changes in 1.1.0 are:

Contributing

We accept contributions via GitHub Pull Requests, but all contributors need to be covered by the standard Google Contributor License Agreement. You can find instructions for this in CONTRIBUTING


All versions of recaptcha with dependencies

PHP Build Version
Package Version
Requires php Version >=5.5
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 paragonie/recaptcha contains the following files

Loading the files please wait ....