<?php

	/***************************************************************\
	|																|
	|	开单大师（专业的房产ERP管理系统）							|
	|																|
	|	© 2017-2022 淮南市银泰软件科技有限公司 All rights reserved	|
	|																|
	|	http://www.kaidandashi.com									|
	|																|
	|	QQ号：984784483												|
	|																|
	\***************************************************************/

	namespace Admin\Controller;
	use Think\Controller;
	class GetfyqrController extends Controller {
		public function index(){
			$fybh = I('fybh');
			$url = $_SERVER['HTTP_HOST'].'/index.php/wap/fangyuan/fyneirong/bianhao/'.$fybh;
			$this->qrcode($url,3,4);
		}
		public function qrcode($url='',$level=3,$size=4){
			ob_end_clean(); //清空所有缓冲区
			//引入二维码生成插件
			Vendor('phpqrcode.phpqrcode');
			$errorCorrectionLevel =intval($level) ;//容错级别 
			$matrixPointSize = intval($size);//生成图片大小 
			//生成二维码图片 
			//echo $_SERVER['REQUEST_URI'];
			$object = new \QRcode();
			$object->png($url, false, $errorCorrectionLevel, $matrixPointSize, 2);   
		}
	}