[英]I've got a qr code output with an exact value but I don't know how to store the generated image. How can I store a qr-code image?
In the code I have a value string as a test and I am getting an output once I scan qr-code.在代码中,我有一个值字符串作为测试,一旦我扫描了二维码,我就会得到一个输出。 I would like to store that qr-code image in a folder.
我想将该二维码图像存储在一个文件夹中。
include 'phpqrcode/qrlib.php';
$value = "test";
if($count > 0)
{
QRcode::png('code data text', 'filename.png'); // creates file
$result = QRcode::png($values); // creates code image and outputs it
directly into browser
}
You have 3 options,你有3个选择,
coded data text
in a file or databasecoded data text
存储在文件或数据库中QRcode::text($codeContents)
)QRcode::text($codeContents)
)QRcode::png($codeContents, $pngAbsoluteFilePath);
QRcode::png($codeContents, $pngAbsoluteFilePath);
Good luck!祝你好运!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.