在之前一段时间里,我发现了ZBlog的用户中心,其中有个做的比较好的LayerCenter,但是这个收费很高,我表示用不起,后面发现唐朝大大提供了用户中心百搭版本,可以支持各种集成,然后有很多大佬们根据这个百搭版本的用户中心做了各种适配,而我有幸拿到了一个天兴用户中心的版本。官方提供的插件,请阅读《ZBlog PHP会员中心插件:用户中心》
毕竟没有付费,是从网络上收集到的资源,其中的第三方登录的功能就用不了,经过尝试解决,还是处理不了,问题是这样的
1、首先配置好qq互联的回调地址、appid、appkey等信息
2、进入到登录页面,点击qq登录
3、完成操作后,提示如图
4、经过调试发现是zb_system/function/c_system_event.php的59行报错
至于为何其中会报错,就有点弄不清楚了,花费了不少时间,既然还解决不了,我不如换种方式解决
5、在应用中心,下载QQ互联插件
6、启用设置,并重新设置回调地址
7、从下方调用内容中获取代码
<a href="https://www.zjh336.cn/zb_system/cmd.php?act=os_qqconnect&type=login" class="os-qqconnect-link"><img src="https://www.zjh336.cn/zb_users/plugin/os_qqconnect/static/icon/qq_d_24_gray.png" alt="QQ登录" /></a>
直接取其中zb_system/cmd.php?act=os_qqconnect&type=login 即可
8、打开可道云文件管理器,在/zb_users/plugin/tx_user_theme目录下搜索/plugin/YtUser/login.php
9、打开全部文件,将zb_users/plugin/YtUser/login.php替换为zb_system/cmd.php?act=os_qqconnect&type=login
10、返回后台首页,清空缓存并重新编译模板
11、再次尝试点击登录页面的qq图标,跳转页面
如有账号,输入用户名密码后点击登录并绑定,如果没有账号,点击又下角生成账户
12、再次点击用户中心,登录界面,显示内容为刚注册用户
13、点击发布文章,显示界面如下,富文本编辑器工具栏内容太少
14、使用可道云文件管理器,打开zb_users/plugin/YtUser/function/yt_event.php
其中工具栏代码toolbars仅仅只有五个,将其中中括号部分替换如下代码
[["fullscreen","source","|","undo","redo","|","bold","italic","underline","fontborder","strikethrough","superscript","subscript","removeformat","formatmatch","autotypeset","blockquote","pasteplain","|","forecolor","backcolor","insertorderedlist","insertunorderedlist","selectall","cleardoc","|","rowspacingtop","rowspacingbottom","lineheight","|","customstyle","paragraph","fontfamily","fontsize","|","directionalityltr","directionalityrtl","indent","|","justifyleft","justifycenter","justifyright","justifyjustify","|","touppercase","tolowercase","|","link","unlink","anchor","|","imagenone","imageleft","imageright","imagecenter","|","simpleupload","insertimage","emotion","scrawl","insertvideo","music","attachment","map","gmap","insertframe","insertcode","webapp","pagebreak","template","background","|","horizontal","date","time","spechars","snapscreen","wordimage","|","inserttable","deletetable","insertparagraphbeforetable","insertrow","deleterow","insertcol","deletecol","mergecells","mergeright","mergedown","splittocells","splittorows","splittocols","charts","|","print","preview","searchreplace","drafts","help"]]
15、后台清空缓存并重新编辑后,查看发布页面,工具栏齐全
修改过的插件已经打包上传到个人网盘中
有需要的可自行下载,直接将文件解压到zb_users/plugin目录下即可,启用天兴用户中心插件时,可先关闭应用中心,待启动后再打开
分享插件列表
1)用户中心(百搭) 11.9
2)天兴工作室用户中心模板 1.2
3)天兴工作室 手机端后台 1.0
4)QQ互联 1.4
5)天兴工作室 后台配色 1.4
还没有评论,来说两句吧...