Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/iaematt/captcha
Esse componente gera imagens captcha para uso em sites PHP.
https://github.com/iaematt/captcha
captcha class composer packagist php php7
Last synced: 12 days ago
JSON representation
Esse componente gera imagens captcha para uso em sites PHP.
- Host: GitHub
- URL: https://github.com/iaematt/captcha
- Owner: iaematt
- License: other
- Created: 2022-04-25T14:45:07.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-04-25T15:12:20.000Z (over 2 years ago)
- Last Synced: 2024-04-19T08:03:09.024Z (9 months ago)
- Topics: captcha, class, composer, packagist, php, php7
- Language: PHP
- Homepage:
- Size: 78.1 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# Captcha @iaematt
[![Maintainer](http://img.shields.io/badge/[email protected]?style=flat-square)](https://github.com/iaematt)
[![Source Code](http://img.shields.io/badge/source-iaematt/captcha-blue.svg?style=flat-square)](https://github.com/iaematt/captcha)
[![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE)##### This component is a simple captcha image generator
Esse componente é um simples gerador de imagem captcha.
# Installation
Captcha is available via Composer:
```bash
"iaematt/captcha": "1.0.*"
```or run
```bash
composer require iaematt/captcha
```# Documentation
##### For details on how to use the component, see the sample folder with details in the component directory.
Para mais detalhes sobre como usar o componente, veja a pasta de exemplo com detalhes no diretório do componente.
@generate
```php
$captcha = new \iaematt\Captcha\Generate();
$captcha->render();
```@verify
```php
$captcha = new iaematt\Captcha\Verify();
$post = $_POST;
if ($captcha->compare($post['captcha'])) {
echo 'The code is correct';
}
```@generate using custom font and font size
```php
$captcha = new \iaematt\Captcha\Generate();
$captcha->setFontFamily(__DIR__ . '/fonts/roboto.ttf');
$captcha->setFontSize(35);
$captcha->render();
```# Contributing
Please see [CONTRIBUTING](https://github.com/iaematt/captcha/blob/master/CONTRIBUTING) for details.
# Support
##### Security: if you discover any security related issues, please e-mail [email protected] instead of using the issue tracker.
Se você descobrir algum problema relacionado à segurança, envie um e-mail para [email protected] em vez de usar o rastreador de problemas.
# Credits
- [Matheus Bastos](https://github.com/iaematt) (Developer)
# License
The MIT License (MIT). Please see [License File](https://github.com/iaematt/captcha/blob/master/LICENSE) for more information.