Anonymous 发表于 2020-3-31 16:07:10

discuz远程附件完整版包含列表页略缩图不显示头像不能上传等【附图】

discuz远程附件完整版包含列表页略缩图不显示头像不能上传等【附图】
关注附件很多地方网上都有,大同小异,真正出问题的地方在:
1.升级后数据库需要升级,执行命令
1 、后台–全局–上传设置–远程附件–启用远程附件:是
2 、上传data/attachment下面的文件夹到远程空间的atta目录下
3 、转换数据库的本地附件的数据为远程附件数据
4 在“后台–站长–数据库–升级”分别执行如下代码
4.1 1、pre_forum_attachment(附件表)
4.2 2、pre_portal_article_title,pre_portal_attachment,pre_portal_topic_pic(门户相关)
4.3 3、由于相册表中的remote取值还有一种情况为remote=2(论坛附件图片保存到相册)pre_home_pic,执行语句:

这里根据后台提示和自己开启的远程服务器的FTP的信息配置就可以,要确保FTP具有以下权限:读取文件、写入文件、删除文件、创建目录、子目录继承。上传data/attachment下面的文件夹到远程空间的atta目录下转换数据库的本地附件的数据为远程附件数据涉及到的数据库表:
pre_forum_attachment(附件表)
pre_home_pic(家园表——这个表的remote字段比较特别,home本地图片—0;home远程图片—1;论坛本地图片—2;论坛远程图片—3)
pre_portal_article_title(门户文章标题表)
pre_portal_attachment(门户文章附件表)
pre_portal_topic_pic(门户专题图片表)在“后台–站长–数据库–升级”分别执行如下代码1、pre_forum_attachment(附件表)
update pre_forum_attachment_0 set remote = '1';
update pre_forum_attachment_1 set remote = '1';
update pre_forum_attachment_2 set remote = '1';
update pre_forum_attachment_3 set remote = '1';
update pre_forum_attachment_4 set remote = '1';
update pre_forum_attachment_5 set remote = '1';
update pre_forum_attachment_6 set remote = '1';
update pre_forum_attachment_7 set remote = '1';
update pre_forum_attachment_8 set remote = '1';
update pre_forum_attachment_9 set remote = '1';2、pre_portal_article_title,pre_portal_attachment,pre_portal_topic_pic(门户相关)update pre_portal_article_title set remote=1;
update pre_portal_attachment set remote=1;
update pre_portal_topic_pic set remote=1;3、由于相册表中的remote取值还有一种情况为remote=2(论坛附件图片保存到相册)pre_home_pic,执行语句:update pre_home_pic set remote=remote+1;


页: [1]
查看完整版本: discuz远程附件完整版包含列表页略缩图不显示头像不能上传等【附图】