Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Increasing memory allocated to PHP-wordpress  (Read 3204 times)

0 Members and 1 Guest are viewing this topic.

sajugovind

  • Guest
Increasing memory allocated to PHP-wordpress
« on: December 27, 2013, 06:56:30 pm »
Increasing memory allocated to PHP

The WP_MEMORY_LIMIT option  allows you to specify the maximum amount of memory that can be consumed by PHP. This setting may be necessary in the event you receive a message such as "Allowed memory size of xxxxxx bytes exhausted".

This setting increases PHP Memory only for WordPress, not other applications. By default, WordPress will attempt to increase memory allocated to PHP to 40MB (code is at beginning of wp-settings.php), so the setting in wp-config.php should reflect something higher than 40MB.

Increase PHP Memory to 64MB

define( 'WP_MEMORY_LIMIT', '64M' ); in wp-config.php

When in the administration area, the memory can be increased or decreased from the WP_MEMORY_LIMIT by defining WP_MAX_MEMORY_LIMIT.

define( 'WP_MAX_MEMORY_LIMIT', '256M' );

Please note, this has to be put before wp-settings.php inclusion.