Wordpress

Wordpress

If you installed a fresh copy of Wordpress or you just upgraded to the latest version of Wordpress 2.9 you may encounter the memory limitation problem with a massage like:

Fatal error: Allowed memory size of 33536532 bytes exhausted (tried to allocate 2587395 bytes) in /home/xxx/public_html/wp-includes/http.php on line 1331

This problem arise due to maximum memory specification amount that can be consumed by PHP, In order to fix such an issue you may apply one the following:

(1)

  • Back up and download the file: wp-settings.php then open it using appropriate php editor (wordpad/notepad will do the job)
  • Search within the file for
       define('WP_MEMORY_LIMIT', '32M');
  • Change 32M to 64M or 96M:
       define('WP_MEMORY_LIMIT', '64M');
  • Upload the newly configured file and replace it with the existing one

(2)


  • Back up and download the file wp-config.php , Open the file wp-config.php using appropriate php editor (wordpad/notepad will do the job)
  • Search within the file for
       define('WP_MEMORY_LIMIT', '32M');
  • If you couldn’t find it just add the follwoing line in the file:
       define('WP_MEMORY_LIMIT', '64M');
  • Upload the newly configured file and replace it with the existing one

(3)


  • Back up and download the file wp-config.php , Open the file wp-config.php using appropriate php editor (wordpad/notepad will do the job)
  • Search within the file for
       define('WP_MEMORY_LIMIT', '32M');
  • If you couldn’t find it just add the following line in the file:
        ini_set('memory_limit', '64M');
  • Upload the newly configured file and replace it with the existing one
  • enjoy :)

Note that this change may not work if your host does not allow for increasing the PHP memory limit. In this case contact your host to increase the PHP memory limit.


  • Share/Bookmark