2017-25 © Pedro Peláez
 

library deathbycaptcha

DeathByCaptcha extension

image

hmphu/deathbycaptcha

DeathByCaptcha extension

  • Saturday, October 1, 2016
  • by hmphu
  • Repository
  • 4 Watchers
  • 3 Stars
  • 16,436 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 2 Versions
  • 6 % Grown

The README.md

DeathByCaptcha PHP Wrapper

Unofficial PHP wrapper for DeathByCaptcha API, (*1)

Installation

The preferred way to install this extension is through composer., (*2)

Either run, (*3)

php composer.phar require --prefer-dist hmphu/deathbycaptcha

or add, (*4)

"hmphu/deathbycaptcha": "*"

to the require section of your composer.json., (*5)

Usage

use hmphu\deathbycaptcha\DeathByCaptchaSocketClient;
use hmphu\deathbycaptcha\DeathByCaptchaClient;

$deathByCaptchaUser = 'Your DBC API Username Here';
$deathByCaptchaPassword = 'Your DBC API Password Here';
$client = new DeathByCaptchaSocketClient($deathByCaptchaUser, $deathByCaptchaPassword);

try {
    $balance = $client->get_balance();
    if($balance > 0){
        /* Put your CAPTCHA file name or opened file handler, and optional solving timeout (in seconds) here: */
        $captcha = $client->decode($img, DeathByCaptchaClient::DEFAULT_TIMEOUT * 2);
        if ($captcha) {
            $text = $captcha['text'];
        }
    }
} catch (DeathByCaptchaAccessDeniedException $e) {
    /* Access to DBC API denied, check your credentials and/or balance */
}

Authors and Contributors

Make with love to DeathByCaptcha service, (*6)

In 2016, PhuHM (@hmphu), http://hmphu.com, (*7)

Support or Contact

Having trouble? [contact me][3], (*8)

The Versions

01/10 2016

dev-master

9999999-dev

DeathByCaptcha extension

  Sources   Download

MIT

by Phu Hoang

deathbycaptcha

23/02 2016

1.0.0

1.0.0.0

DeathByCaptcha extension

  Sources   Download

Apache-2.0

by Phu Hoang

deathbycaptcha