Skip to content

Instantly share code, notes, and snippets.

@putzflorian
Created March 7, 2014 09:19
Show Gist options
  • Select an option

  • Save putzflorian/9408250 to your computer and use it in GitHub Desktop.

Select an option

Save putzflorian/9408250 to your computer and use it in GitHub Desktop.
Render qr codes
<?php
public function QrcodeAction () {
$url = $this->getParam("url");
$codeSettings = array(
'text' => $url,
'backgroundColor' => '#FFFFFF',
'foreColor' => '#000000',
'padding' => 0, //array(10,5,10,5),
'moduleSize' => 10
);
$renderSettings = array();
$code = Pimcore_Image_Matrixcode::render('qrcode', $codeSettings, "svg", $renderSettings);
echo $code;
exit;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment