0

I am trying to increase WP Memory Limit: so that I can use Fusion Builder, and other things, with WordPress but the status for the plugin is still saying I only have the limit set to 40M, even with the code lines below added to wp-config.php, when I want it to be at least 256M.

I am on a cloud server with WHM/Cpanel so network admin is basically me. I think I have already maxed php.ini so its not that.

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

Please help.

  • you should ask your support first if you can change memory settings at all – Mark Kaplun May 6 '16 at 3:03
  • 4
    If you're using a shared host service, there's a high probability that you're not allowed to change that setting because you're usually sharing the same resources with hundreds or even more other sites/apps. – N00b May 6 '16 at 3:15
  • Sorry i thought I wrote that I am self-hosting on a cloud server with whm/cpanel. – Gary Carlyle Cook May 6 '16 at 3:24
  • Check phpinfo to see what the memory limit is there; otherwise you might want to ask at StackOverflow for more general PHP assistance – Tim Malone May 6 '16 at 3:27
  • I set the PHP mem limit to 256M. In fact I made sure nothing in php.ini was below that. Just to rules that out and yet the issue persists. It's annoying!! =) – Gary Carlyle Cook May 6 '16 at 4:04
-1

Try adding to wp-includes/default-constants.php You'll probably see the default values of 40M starting around line #20, change these values. My setup is as follows:

// set memory limits
    if ( !defined('WP_MEMORY_LIMIT') ) {
        if ( is_multisite() ) {
            define('WP_MEMORY_LIMIT', '256M');
        } else {
            define('WP_MEMORY_LIMIT', '256M');
        }
    }
| improve this answer | |
  • Never change in core! – Sumit May 7 '16 at 4:56
  • got a better suggestion? it may be reset but at least it will work for now possibly. – Gary Carlyle Cook May 7 '16 at 20:48
  • Although, this is not a perfect solution it did solve my specific issue. People have to be aware that there are somewhat good reasons those limits are in the core and also that core edits will be wiped when Wordpress updates. Saying all that, I am marking this as best answer personally. – Gary Carlyle Cook May 7 '16 at 23:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.