public function index() { //print_r($_SERVER['HTTP_HOST'].'/Uploads/img/201508/1439592462.jpg'); yf_down('http://' . $_SERVER['HTTP_HOST'] . '/Uploads/img/201508/1439592462.jpg'); //$this->assign_global(); //Model('index')->get_jsdk(); }
public function qrcode() { if ($_POST) { $url = yf_empty($_POST['url'], "请输入要生成二维码的链接"); $size = yf_empty(intval($_POST['size']), 10, 'size'); $name = yf_empty($_POST['name'], '', true); $status = yf_empty(intval($_POST['status']), 0, true); if ($status == 0) { $path = yf_qrcode($url, $size, true, $name); yf_down($path); } else { $path = yf_qrcode($url, $size); // $this->assign("code", $path); } } $this->display("qrcode.html"); }