[Resolved] Tip: try fixing "memory exhausted" errors in .htaccess rather than wp-config.php
A co-worker solved a problem for me which I didn’t see addressed in the Codex and only found in the Forums after the fact, so I thought I’d pass it along.
The problem: after I upgraded to WP 3.0.1, I got the dreaded “memory exhausted” error.
Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 393216 bytes) in /export/httpd/vhosts/xxxxxxxx/data/wp-admin/menu.php on line 235
The suggestion in numerous forum posts is to raise the memory limit in wp-config.php by inserting a line like this:
However, that didn’t work for me. The solution was to raise the memory limit in .htaccess instead:
php_value memory_limit 32M
After I knew the answer I found it embedded in various long threads in the Forums, such as this useful comment by MichaelH:
Maybe this belongs in the FAQ? The only reference to .htaccess memory_limit I see in http://codex.wordpress.org/FAQ_Working_with_WordPress is in reference to imports rather than “memory size exhausted” errors.
- The topic ‘[Resolved] Tip: try fixing "memory exhausted" errors in .htaccess rather than wp-config.php’ is closed to new replies.