下载论坛附件时,附件名前自动加网站名 显示为“你的网站名称_附件原名”
3 |" D. r$ V2 m5 _: z3 W% I: G& N
一:打开source/module/forum/forum_attachment.php
+ z$ }, ]& O! P; f/ T& L4 h3 i
找到:
- $thread && $attachexists = TRUE;
复制代码改为:
- $thread && $attachexists = TRUE;
) R0 m2 T( Q8 J+ ]0 @ - $attach['filename'] = '你的网站名称_'.$attach['filename'];
( o [7 D( G1 j* B; `8 |) R
复制代码二:打开source/function/function_attachment.php
0 `/ O* e% W% ^% E' n/ V O找到:
改为:
- continue;8 P y. m! O# _ ]
- $attach['filename'] = '你的网站名称_'.$attach['filename'];
复制代码把上面代码里的“你的网站名称”修改成你所需要的附件前缀名就可以了
0 u2 X3 c# e/ J$ t修改好,上传覆盖更新即可。演示见本站附件(点下载就可以看到)