Home  >  Article  >  php教程  >  微信公众号自定义分享内容实现

微信公众号自定义分享内容实现

WBOY
WBOYOriginal
2016-06-08 17:20:082490browse

微信公众号号在手机中通过api接口可以实现自定义分享内容了,下面我们来看这个接口的实现步骤。


一、准备阶段

公众号一个,微网站一个。
 

二、绑定域名

先登录微信公众平台进入“公众号设置”的“功能设置”里填写“JS接口安全域名”。
备注:登录后可在“开发者中心”查看对应的接口权限。
 
三、代码

四、视图显示

在需要调用JS接口的页面引入如下JS文件,(支持https):http://res.wx.qq.com/open/js/jweixin-1.0.0.js
通过config接口注入权限验证配置

五、大功告成

基本上的流程就是这样了,比较麻烦的一点就是生成签名那一块,注意一点就行了

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn