微信开发 接口 创建带参数的二维码 PHP qrcode

 

function create_qr()//创建二维码////////////
{
    $data['action_name'] = 'QR_LIMIT_SCENE';
    $data['action_info']['scene']['scene_id'] = 1;

    $qrcode_return = https_request("https://api.weixin.qq.com/cgi-bin/qrcode/create?access_token=".getAccessToken(),json_encode($data));
 
    echo "<img src='https://mp.weixin.qq.com/cgi-bin/showqrcode?ticket=".urlencode($qrcode_return['ticket'])."' >";
}

 

posted @ 2018-05-21 17:04  WilliamShaw  阅读(1237)  评论(0编辑  收藏  举报