Forgot password?
 Create new account
View 381|Reply 11

已升级Discuz! X3.5

[Copy link]

3146

Threads

8493

Posts

610K

Credits

Credits
66158
QQ

Show all posts

hbghlyj Posted at 2023-9-23 18:31:33 |Read mode
Last edited by hbghlyj at 2023-11-8 10:22:00升级教程操作的,若发现缺失功能/运行错误,欢迎指出!

3146

Threads

8493

Posts

610K

Credits

Credits
66158
QQ

Show all posts

 Author| hbghlyj Posted at 2023-9-24 21:23:05
Last edited by hbghlyj at 2023-11-8 10:23:00点评换行、连续空白

Comment

连续空白           连续空白
换行
换行  Posted at 2023-9-24 23:26

3146

Threads

8493

Posts

610K

Credits

Credits
66158
QQ

Show all posts

 Author| hbghlyj Posted at 2023-9-25 04:28:39

标题字数

Last edited by hbghlyj at 2023-11-8 10:23:00X3.5标题字数增加至255

3146

Threads

8493

Posts

610K

Credits

Credits
66158
QQ

Show all posts

 Author| hbghlyj Posted at 2023-11-3 22:14:05
Last edited by hbghlyj at 2023-11-8 10:23:00标签长度 修改

Comment

第 119 行的真的不用改吗?  Posted at 2023-11-3 22:33

701

Threads

110K

Posts

910K

Credits

Credits
94167
QQ

Show all posts

kuing Posted at 2023-11-3 22:26:25

关于去除标签限制

Last edited by kuing at 2023-11-8 21:31:00先前楼主的改法是:
  1. source/class/class_tag.php
  2.                         if(preg_match('/^([\x7f-\xff_-]|\w|\s){2,20}$/', $tagname)) {
  3. 改为
  4.                         if(mb_strlen($tagname)>2&&mb_strlen($tagname)<30) {
Copy the Code

这导致两个汉字的 tag 无效

后来楼主将第一个 mb_strlen 改为 strlen

strlen() 与 mb_strlen() 的定义是啥



另外,source/class/class_tag.php 里除了第 31 行里有
  1. if(preg_match('/^([\x7f-\xff_-]|\w|\s){2,20}$/', $tagname))
Copy the Code

之外,还有第 119 行的
  1. if(preg_match('/^([\x7f-\xff_-]|\w|\s){2,20}$/', $newtag))
Copy the Code

Comment

strlen只是字节,mb_strlen考虑字符编码吧  Posted at 2023-11-4 00:07

手机版Mobile version|Leisure Math Forum

2025-4-20 21:52 GMT+8

Powered by Discuz!

× Quick Reply To Top Return to the list