当前位置:网站首页>Phpcms V9 remove the phpsso module
Phpcms V9 remove the phpsso module
2022-06-26 09:02:00 【CMS applet plug-in [official]】
phpsso Has always been phpsso Users' complaints , Because for most enterprise stations , There is no need to log in with multiple applications , Therefore, there is no need to phpsso, however phpcms The official didn't design a switch or something , It's mandatory phpsso, Even if it is mandatory , And we are often phpsso Of “ Communications ” stop , So many people are thinking about how to remove phpsso, Let the member function no longer depend on phpsso.
Because I want to develop phpcms v9 Wechat applet plug-in , It needs to connect with the member system , But damn phpsso It's crazy , And it is troublesome to get the user's Avatar , Because the default phpsso Your avatar is not stored , Therefore, it is difficult to read , So I decided to cut it down phpsso
(1) to v9_member Add a field to the table avatar, Used to store avatars , Set up varchar type .
(2) Comprehensive rectification phpcms\modules\member Under the index.php, Post some code :

(3) Comprehensive rectification phpcms\modules\member Under the member.php,content.php Basic modification and index.php Agreement
(4) Modify the code of all calling avatars in the foreground and background templates , The original no longer supports , And abolish the default method of modifying the avatar in the foreground , Change to phpcms Default image upload class , Picture call can be used directly $memberinfo['avatar'] and get_memberavatar($userid,$is_userid='1','') Method call .
(5) modify phpcms\libs\functions\global.func.php Medium get_memberavatar Method changed to :
- function get_memberavatar($uid, $is_userid='1', $size='30') {
- if($is_userid) {
- $db = pc_base::load_model('member_model');
- $memberinfo = $db->get_one(array('userid'=>$uid));
- if(isset($memberinfo['userid'])) {
- $uid = $memberinfo['userid'];
- $avatar = $memberinfo['avatar'];
- } else {
- return false;
- }
- }
- }
According to the above modification , Do a test , close phpsso after , You can still register your members at , At present, no other bug,.
To refuse to reach out to the party , The source code will not be released for the time being , You can contact me if you need , If you think it works for you , You can reward me , It doesn't matter how much , Respect the fruits of labor , It's not easy , Understand more ! Add me WeChat :15137100750 or QQ:2863868475
边栏推荐
- How to set the shelves and windows, and what to pay attention to in the optimization process
- Matlab drawing checkerboard (camera calibration)
- 在哪个软件上开户比较安全
- 拦截器与过滤器的实现代码
- Backward usage
- Computer mall based on SSM
- Data warehouse (1) what is data warehouse and what are the characteristics of data warehouse
- 直播回顾 | smardaten李鸿飞解读中国低/无代码行业研究报告:风向变了
- Line detection_ nanyangjx
- Yolov5 advanced camera real-time acquisition and recognition
猜你喜欢

Detailed process of generating URDF file from SW model

Exploration of webots and ROS joint simulation (I): software installation

Euler function: find the number of numbers less than or equal to N and coprime with n

Partial summary of 45 lectures on geek time MySQL

yolov5进阶之零环境快速创建及测试

反爬之验证码识别登录 (OCR字符识别)

Fast construction of neural network

Yolov5 advanced level 2 installation of labelimg

Yolov5进阶之二安装labelImg

Matlab drawing checkerboard (camera calibration)
随机推荐
Reverse crawling verification code identification login (OCR character recognition)
1.21 study logistic regression and regularization
How to use leetcode
phpcms v9去掉phpsso模块
Euler function: find the number of numbers less than or equal to N and coprime with n
Yolov5进阶之一摄像头实时采集识别
Sublime Text3 common plug-ins
拦截器与过滤器的实现代码
Code de mise en œuvre de l'intercepteur et du filtre
1.23 neural network
Yolov5 advanced camera real-time acquisition and recognition
Principle of playing card image segmentation
上下架和橱窗推荐如何设置,优化过程需要注意的地方
Slider verification - personal test (JD)
Convert verification code image to tfrecord file
Detailed process of generating URDF file from SW model
phpcms v9后台增加阅读量字段,可任意修改阅读量
Exploration of webots and ROS joint simulation (II): model import
浅谈一下Type-C接口发展历程
Isinstance() function usage