进行操作前,请备份数据库。
3、数据库执行sql语句。
论坛:
1 2 3 4 5 6 7 8 9 10 |
update pre_forum_attachment_0 set remote=1 where remote=0; update pre_forum_attachment_1 set remote=1 where remote=0; update pre_forum_attachment_2 set remote=1 where remote=0; update pre_forum_attachment_3 set remote=1 where remote=0; update pre_forum_attachment_4 set remote=1 where remote=0; update pre_forum_attachment_5 set remote=1 where remote=0; update pre_forum_attachment_6 set remote=1 where remote=0; update pre_forum_attachment_7 set remote=1 where remote=0; update pre_forum_attachment_8 set remote=1 where remote=0; update pre_forum_attachment_9 set remote=1 where remote=0; |
门户:
1 2 3 |
update pre_portal_article_title set remote=1 where remote=0; update pre_portal_attachment set remote=1 where remote=0; update pre_portal_topic_pic set remote=1 where remote=0; |
相册:
相册表中的remote取值还有一种情况为remote=2(论坛附件图片保存到相册)
1 |
update pre_home_pic set remote=remote+1; |
二、远程转到本地后台关闭远程附件设置,将附件移动到本地服务器的data/attachment目录后执行sql即可。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
update pre_forum_attachment_0 set remote=0 where remote=1; update pre_forum_attachment_1 set remote=0 where remote=1; update pre_forum_attachment_2 set remote=0 where remote=1; update pre_forum_attachment_3 set remote=0 where remote=1; update pre_forum_attachment_4 set remote=0 where remote=1; update pre_forum_attachment_5 set remote=0 where remote=1; update pre_forum_attachment_6 set remote=0 where remote=1; update pre_forum_attachment_7 set remote=0 where remote=1; update pre_forum_attachment_8 set remote=0 where remote=1; update pre_forum_attachment_9 set remote=0 where remote=1; update pre_portal_article_title set remote=0 where remote=1; update pre_portal_attachment set remote=0 where remote=1; update pre_portal_topic_pic set remote=0 where remote=1; update pre_home_pic set remote=remote-1; |
注:(where remote=0表示本地,where remote=1表示远程, pre_表示数据库表前缀)
Mozilla/5.0 (Windows NT 6.1) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.802.30 Safari/535.1 SE 2.X MetaSr 1.0
0 呵呵。学习了。感触良多!
0
Mozilla/5.0 (Windows NT 6.1) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.802.30 Safari/535.1 SE 2.X MetaSr 1.0
0 三天两头过来看一看,每次看完都有新体验!
Mozilla/5.0 (Windows NT 6.1) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.802.30 Safari/535.1 SE 2.X MetaSr 1.0
0 这里真心不错,每次来都有新收获!
Mozilla/5.0 (Windows NT 6.1) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.802.30 Safari/535.1 SE 2.X MetaSr 1.0
0 到你的博客走一趟,如同阳光洒在我脸上,心里暖洋洋!