更改 WordPress 中的永久链接设置会出现“致命错误:内存不足”

发布于 2024-12-24 17:48:04 字数 759 浏览 0 评论 0原文

我尝试更改我的 WordPress 网站的 URL 结构。我在互联网上研究时遇到以下错误

"Fatal error: Out of memory (allocated 31981568) (tried to allocate 1111781 bytes) in ../wp-includes/wp-db.php on line 774"

,并得到了这个解决方案:

1. Try adding this line to your wp-config.php file:
define('WP_MEMORY_LIMIT', '64M');

2. If you have access to your PHP.ini file, change the line in PHP.ini
If your line shows 32M try 64M:
memory_limit = 64M ; Maximum amount of memory a script may consume (64MB)

3. If you don't have access to PHP.ini try adding this to an .htaccess file:
php_value memory_limit 64M

4. Talk to your host.  

对我来说没有任何作用,我没有尝试第二个选项,因为我无权访问 php.ini 文件。

我的问题是为什么更改简单的 URL 会导致此问题?这是因为缓存还是其他原因吗?

任何帮助将不胜感激。

I tried to change the URL structure of my Wordpress site. I am getting following error

"Fatal error: Out of memory (allocated 31981568) (tried to allocate 1111781 bytes) in ../wp-includes/wp-db.php on line 774"

I researched in internet and I got this solution:

1. Try adding this line to your wp-config.php file:
define('WP_MEMORY_LIMIT', '64M');

2. If you have access to your PHP.ini file, change the line in PHP.ini
If your line shows 32M try 64M:
memory_limit = 64M ; Maximum amount of memory a script may consume (64MB)

3. If you don't have access to PHP.ini try adding this to an .htaccess file:
php_value memory_limit 64M

4. Talk to your host.  

Nothing worked for me, I did not try the second option since I do not have access to php.ini file.

My Question is why changing an simple URL cause this issue? Is this because of cache or some thing?

Any help would be greatly appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

绾颜 2024-12-31 17:48:04

WordPress 需要内存。与您的房东交谈,询问他们您的帐户可以获得多少费用,并要求更多。您可能需要更改主机。

WordPress needs RAM. Talk to your host and ask them how much your account gets and ask for more. You might have to change hosts.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文