Sunday 21 July 2013

Increasing PHP memory limits

 

Most Web hosting providers limit the amount of memory any one PHP

script or program file can use on the Web server at any given time. PHP is at the core of WordPress (see Book II, Chapter 3), and by default, WordPress attempts to set the PHP memory limit to 32MB. However, if you see PHP memory limit errors on your Web site, such as

 

PHP Fatal error: Allowed memory size of 33554432 bytes exhausted
(tried to allocate 6233929 bytes) …

 

The PHP memory limit needs to be increased to run the PHP script or file. That memory limit error tells you that the PHP script was attempting to allocate 64MB of memory; however, the allowed memory size set by the server is limited to 32MB, which is the reason for the error.

0 comments:

Post a Comment