Example #1
0
 /**
  * QRcode a owner entity.
  *
  * @Route("/", name="owner_qrcode")
  */
 public function generateQRCode()
 {
     $entity = new Owner();
     $qrCode = new QrCode();
     $qrCode->setText("I would love to change the world, but they won't give me the source code");
     $qrCode->setSize(200);
     echo $qrCode->image("image alt", ['class' => 'qr-code-img']);
 }
Example #2
0
<?php

include_once "../vendor/autoload.php";
use Arcanedev\QrCode\QrCode;
$qrCode = new QrCode();
$qrCode->setText("I would love to change the world, but they won't give me the source code");
$qrCode->setSize(200);
echo $qrCode->image('ARCANEDEV', ['style' => 'width: 150px;']);