1 && argv(1) === 'qr') {
$t = $_GET['qr'];
require_once('addon/qrator/phpqrcode/phpqrcode.php');
header("Content-type: image/png");
QRcode::png(($t) ? $t : '.');
killme();
}
}
/**
* @brief Returns an QR-code image from a value given in $match[1].
*
* @param array $match
* @return string HTML img with QR-code of $match[1]
*/
function qrator_bb_qr($match) {
return '';
}
function qrator_bbcode(&$a,&$b) {
if (strpos($b,'[/qr]') !== false) {
$b = preg_replace_callback("/\[qr\](.*?)\[\/qr\]/ism", 'qrator_bb_qr', $b);
}
}
function qrator_content(&$a) {
$header = t('QR Generator');
$prompt = t('Enter some text');
$o .= <<< EOT