首先,我要澄清的是,这似乎是一个与已经涉及的众多迁移问题不同的问题。
简而言之,我已经根据WP手册将我的站点迁移到了一个新域(都在根目录下,没有目录更改),但是现在所有页面中的图像都缺少缩略图;仅按其名称显示。单击他们的链接/名称会显示完整的图像,这是应该的。
查看页面源代码,WP甚至没有尝试插入缩略图-好像它认为它不存在!
媒体上载程序显示所有图像,但缺少任何缩略图&;只显示一个占位符。单击View(视图)可以看到完整的工作图像。
使用“重新生成缩略图”插件,它会弹出错误:“在处找不到最初上载的图像文件”-在?看起来这可能是数据库中的一个小问题,尽管它仍然能够将我指向原始文件。
&上载新图像;显示无任何问题。
想法?
SO网友:Przemek Maczewski
Domain change
这种错误可能是由存储在数据库中的图像URL中的主机名错误引起的。
必须用新域替换保留旧域的字符串:
http://olddomain.com --> http://newdomain.com
在每个混合过程中,我都使用以下推荐工具:
https://interconnectit.com/products/search-and-replace-for-wordpress-databases/将其上载到WP根目录并在浏览器中打开。然后按照步骤仔细阅读说明和警告。
Database prefix change
使用此工具可以解决其他潜在问题:更改数据库表前缀。如果迁移过程包括为DB表引入一个新的前缀(希望比默认的更安全),那么更改必须反映在一些DB记录中。
因此,也可以使用上面的工具在以下两个表中搜索并替换旧前缀,例如用je9128d\\uuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuu
je9128d\\U用户元