[英]WordPress Database Error: [Table 'databasename.wp_users' doesn't exist] SELECT * FROM wp_users WHERE user_login = 'Username'
I was developing a WordPress theme locally on a Mac (OSx Sierra) using XAMPP.我正在使用 XAMPP 在 Mac (OSx Sierra) 上本地开发 WordPress 主题。 It was set up so that when I typed localhost/ThemeName
into the URL, I was taken to my site.它被设置为当我在 URL 中输入localhost/ThemeName
,我被带到我的站点。 I restarted my computer after installing some updates and now when I go to localhost/ThemeName
I get this:我在安装了一些更新后重新启动了我的计算机,现在当我转到localhost/ThemeName
我得到了这个:
Obviously I don't want another WordPress installation - it's already installed.显然我不想要另一个 WordPress 安装 - 它已经安装了。 After checking around, I found this article which seems to address a similar problem.检查后,我发现这篇文章似乎解决了类似的问题。 He suggests 'deleting both the wp_users
and wp_usermeta
tables', but I don't know what he means by 'importing them from backups made from the live server'.他建议“同时删除wp_users
和wp_usermeta
表”,但我不知道他所说的“从实时服务器的备份中导入它们”是什么意思。
In phpMyAdmin, my database looks like this:在 phpMyAdmin 中,我的数据库如下所示:
As you can see, I get an error message for every table within the Database for my theme - wp_commentmeta
, wp_comments
, wp_links
, wp_options
, etc. - if I click on any of those I get a message saying that the table doesn't exist.如您所见,对于我的主题的数据库中的每个表,我都会收到一条错误消息 - wp_commentmeta
、 wp_comments
、 wp_links
、 wp_options
等 - 如果我单击其中任何一个,我会收到一条消息说该表不存在. I tried to 'drop' the wp_users
and wp_usermeta
tables but they're still there and now the 'drop' option is actually gone:我试图“删除” wp_users
和wp_usermeta
表,但它们仍然存在,现在“删除”选项实际上消失了:
Please help if you know what to do, thanks!如果您知道该怎么做,请帮助,谢谢!
EDIT : After going ahead and entering Site Title, Email Address, and hitting Install WordPress, I received thousands of error messages:编辑:继续输入站点标题、电子邮件地址并点击安装 WordPress 后,我收到了数千条错误消息:
And so on and so on.等等等等。
Open your terminal and run:打开终端并运行:
sudo /opt/lampp/lampp restart
Then, run your Wordpress installation normally.然后,正常运行 Wordpress 安装。
I restarted Apache and switched to a different internet connection at a different location.我重新启动了 Apache 并在不同的位置切换到不同的互联网连接。 I can go to localhost/MyWPTheme and it works just fine.我可以去 localhost/MyWPTheme ,它工作得很好。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.