PHP生成二维码方法

<?php

//先下载一份phpqrcode类,下载地址http://down.51cto.com/data/780947
require_once("phpqrcode/phpqrcode.php"); //包含类库文件
$value="hello,我叫朱雪礼,是一名php程序员,目前就职于北京市微名互动信息技术有限公司";
$errorCorrectionLevel = 'L';
$matrixPointSize = 4;//
$filename="我的名片.png";
QRcode::png($value, $filename, $errorCorrectionLevel, $matrixPointSize,$margin);

?>

/*
    $value数据
    $filename 保存的图片名称
    $errorCorrectionLevel 错误处理级别
    $matrixPointSize 每个黑点的像素
    $margin 图片外围的白色边框像素  可不填
*/
原文地址:https://www.cnblogs.com/myphper/p/3227384.html