} require_once DEDEINC . '/payment/' . $rs['code'] . '.php'; $pay = new $rs['code'](); $payment = ""; if ($rs['code'] == "cod" || $rs['code'] == "bank") { $order = $buyid; $payment = "member"; } else { $order = array('out_trade_no' => $buyid, 'price' => sprintf("%01.2f", $price)); require_once DEDEDATA . '/payment/' . $rs['code'] . '.php'; } $button = $pay->GetCode($order, $payment); $dtp = new DedeTemplate(); $carts = array('orders_id' => $buyid, 'cart_count' => '1', 'price_count' => sprintf("%01.2f", $price)); $row = $dsql->GetOne("SELECT pname,money FROM #@__member_operation WHERE buyid='{$buyid}'"); $dtp->SetVar('pay_name', $row['pname']); $dtp->SetVar('price', $row['money']); $dtp->SetVar('pay_way', $rs['name']); $dtp->SetVar('description', $rs['description']); $dtp->SetVar('button', $button); $dtp->Assign('carts', $carts); $dtp->LoadTemplate(DEDEMEMBER . '/templets/shops_action_payment.htm'); $dtp->Display(); exit; } /** * 加密函数 * * @access public * @param string $string 字符串 * @param string $operation 操作
if (!in_array($type, array('list', 'arc', 'index'))) { $url = "http://2v.dedecms.com"; } if ($action == 'get_qrcode') { if ($type == 'arc') { $url = $cfg_basehost . $cfg_plus_dir . '/view.php?aid=' . $id; } elseif ($type == 'list') { $url = $cfg_basehost . $cfg_plus_dir . '/list.php?tid=' . $id; } if ($id == 0) { $url = "http://2v.dedecms.com"; } if ($type == 'index') { $url = $cfg_basehost . $cfg_plus_dir . '/index.php'; } header("Content-Type: image/png"); $params = array(); $params['data'] = $url; $params['size'] = 6; $qrcode = new DedeQrcode(); $qrcode->generate($params); } else { header("Content-Type: text/html; charset={$cfg_soft_lang}"); $dtp = new DedeTemplate(); $tplfile = DEDETEMPLATE . '/plus/qrcode.htm'; $dtp->LoadTemplate($tplfile); $dtp->SetVar('id', $id); $dtp->SetVar('type', $type); $dtp->Display(); exit; }