<?php
#php判断微信还是支付宝
/*$tel=isset($_GET["tel"])?$_GET["tel"]:'';
$userId = '';
switch ($tel)
{
case '你的支付宝账号': $userId = '这里改成你的userId'; break;
}*/
if (strpos($_SERVER['HTTP_USER_AGENT'], 'MicroMessenger') == true) {
$browser = 'WeChat';//微信浏览器
} else if (strpos($_SERVER['HTTP_USER_AGENT'], 'AlipayClient') == true) {
echo '11111111111';
header("Location: alipays://platformapi/startapp?appId=09999988&actionType=toAccount&goBack=NO&amount=1.00&userId=支付宝账号userId&memo=转账测试");
exit;
$browser = 'Alipay';//支付宝浏览器
} else {
$browser = "Other";//不是微信和支付宝
}
//header("Location:alipays://platformapi/startapp?saId=10000007&clientVersion=3.7.0.0718&qrcode=https://qr.alipay.com/a7x03476g3ncihbvk0hs59f");
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width,minimum-scale=1.0, maximum-scale=1.0">
<title></title>
<meta name='description' content=''/>
<meta name='keywords' content=''/>
<style type="text/css">
body {
margin: 50px;text-align:center;
}
textarea {width:350px;height:400px;border: 0 none;outline-style: none;resize:none}
</style>
</head>
<body>
技术支持1260770160
</body>
</html>
技术支持 1260770160,欢迎交流。
文章来源: 博客园
- 还没有人评论,欢迎说说您的想法!