日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

appcan 微信支付

發布時間:2024/4/17 编程问答 50 豆豆
生活随笔 收集整理的這篇文章主要介紹了 appcan 微信支付 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

客戶端

<!DOCTYPE html> <html class="um landscape min-width-240px min-width-320px min-width-480px min-width-768px min-width-1024px"><head><title></title><meta charset="utf-8"><meta name="viewport" content="target-densitydpi=device-dpi, width=device-width, initial-scale=1, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"><link rel="stylesheet" href="css/fonts/font-awesome.min.css"><link rel="stylesheet" href="css/ui-box.css"><link rel="stylesheet" href="css/ui-base.css"><link rel="stylesheet" href="css/ui-color.css"><link rel="stylesheet" href="css/appcan.icon.css"><link rel="stylesheet" href="css/appcan.control.css"><link rel="stylesheet" type="text/css" href="css/index.css"><script type="text/javascript">var prepayId;function getPrepayId(){// alert('getPrepayId'); $.ajax({url : 'http://www.網址.com/index.php?g=api&m=Api&a=getPrepayId',type : "post",data : {order_no:訂單號,uid: uid,},datatype : "json",timeout : 30000,success : function(data, status, requestCode, response, xhr) {data = JSON.parse(data);if (data.code == 1) {alert(1);var params = data.data;var data = JSON.stringify(params);alert(data);uexWeiXin.getPrepayId(data);} else {alert(0);alert(data.tips);}},error : function(xhr, erroType, error, msg) {alert('網絡問題');}});}function startPay(){alert(prepayId);$.ajax({url : 'http://網址.com/index.php?g=api&m=Api&a=startPay',type : "POST",data : {prepayid:prepayId,noncestr:'weradfdgdvccfexs1',},datatype : "json",timeout : 30000,success : function(data, status, requestCode, response, xhr) {data = JSON.parse(data);if (data.code == 1) {var params = data.data;var data = JSON.stringify(params);uexWeiXin.startPay(data);} else {alert(data.tips);}},error : function(xhr, erroType, error, msg) {appcan.window.openToast("獲取數據失敗", 2000, 5, 0);}});}
//注冊回調函數window.uexOnload
= function(){uexWeiXin.cbGetPrepayId = cbGetPrepayId;uexWeiXin.cbStartPay = cbStartPay;}function cbGetPrepayId(info){console.log(info);alert(info);prepayId = JSON.parse(info).prepay_id;alert('prepayId:'+prepayId);}function cbStartPay(info){console.log(info);alert('支付成功:'+info);}</script></head><body class="um-vp bc-bg" ontouchstart><div class="tit">支付</div><div class="conbor"><div class="consj"><input class='btn' type='button' value='getPrepayId' οnclick='getPrepayId()'><input class='btn' type='button' value='startPay' οnclick='startPay()'></div></div></body><script src="js/appcan.js"></script><script src="js/appcan.control.js"></script></body><script>appcan.ready(function() {uexWeiXin.registerApp('wx4705bd987b714abb');});</script> </html>

?

php 服務器端?

?

?

??

轉載于:https://www.cnblogs.com/tingfengqieyu/p/5338096.html

總結

以上是生活随笔為你收集整理的appcan 微信支付的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。