码迷,mamicode.com
首页 > 微信 > 详细

asp源码微信公众号验证消息真实性

时间:2018-10-12 13:48:10      阅读:211      评论:0      收藏:0      [点我收藏+]

标签:init   initial   port   拉取   微信   时间   userinfo   render   viewport   

<%
Openid = Wx.Get_Openid
Result = Wx.Get_UserInfo(Openid)
Function sex(v)
if v=1 then
sex = "男"
else
sex = "女"
end if
End Function
%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="renderer" content="webkit" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title>拉取用户基本信息</title>
<style>
img {
border: none;
border-radius: 100%;
}
</style>
</head>
<body>
<p>
<%
If Result(7) = 1 Then
Wx.Echo "openid:"&Openid
Wx.Echo "昵称:"&Result(0)
Wx.Echo "性别:"&sex(Result(1))
Wx.Echo "头像:<img src=‘"&Result(2)&"‘ height=‘50‘>"
Wx.Echo "来自:"&Result(3)&"·"&Result(4)&"·"&Result(5)
Wx.Echo "关注时间:"&DateAdd("s",Result(6),"1970-01-01 08:00:00")
Else
Wx.Echo Openid&"未关注公众号呢"
End If
%>

asp源码微信公众号验证消息真实性

标签:init   initial   port   拉取   微信   时间   userinfo   render   viewport   

原文地址:https://www.cnblogs.com/lytocnc/p/9777242.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!