Fatal Error: Allowed Memory Size of 134217728 Bytes Exhausted (CodeIgniter + XML-RPC)

前端 未结 29 2528
天涯浪人
天涯浪人 2020-11-21 22:57

I have a bunch of client point of sale (POS) systems that periodically send new sales data to one centralized database, which stores the data into one big database for repor

29条回答
  •  失恋的感觉
    2020-11-21 23:22

    Rather than changing the memory_limit value in your php.ini file, if there's a part of your code that could use a lot of memory, you could remove the memory_limit before that section runs, and then replace it after.

    $limit = ini_get('memory_limit');
    ini_set('memory_limit', -1);
    // ... do heavy stuff
    ini_set('memory_limit', $limit);
    

提交回复
热议问题