Skip to content

xxggabriel/certificate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gerador de certificado

Certificate, é uma biblioteca para gerar certificado automaticamente com o PHP, e também pode criar QR code nos certificados.

Requisitos do servidor

  • ext-gd
  • etx-curl

Composer Install

composer require xxggabriel/certificate:1.1

Gerar Certificado

<?php 
require_once "vendor/autoload.php";

header("Content-Type: image/jpeg");
use Certificate\App;

$cert = new App('img/background.jpg');

$cert->createImage([
        ['Certificado', 32, 330, 150,"#333", "/fonts/Bevan/Bevan-Regular.ttf", 0],
        // ['Texto', tamanho da fonte, posição X, posição Y, 
        // Cor da font em hexadecimal, arquivo da font, Angulo do texto],
    ]);
    
$cert->QRCode('https://github.com/xxggabriel', 150, 650, 450);
// $cert->QRCode( Informação para o QR code(como link, codigo ou texto), 
// Tamanho em pixel, Posição X, Posição Y);

$cert->run();

Certificado Gerado

Salvar Certificado

$cert->run(__DIR__);

Dependência

Foi utilizado a API do Goqr, para gerar os QR code.

Licença

A biblioteca Certificate é um software de código aberto licenciado sob a licença MIT.

About

A certificate and diploma generator. PHP 7+

Resources

Stars

Watchers

Forks

Packages

 
 
 

Languages