script will exit and a fatal error will be thrown if it has exhausted all the allocated memory.
PHP Fatal error: Allowed memory size of xxxx bytes exhausted (tried to allocate yyyy) in yourscript.ph
This is to protect the system in the case that a rogue
script or application consume more memory that the system can handle.
You can fix the issue by allocating more memory to your
scripts and there are a few ways to do this.
hosting, you can change the memory limit configuration from your
Steps to change memory limit for PHP in cPanel:
- Log in to your
2. Click on Select PHP Version from the Software section.
3. Click on Options tab at the top of the page.
option and click on the dropdown icon.
5. Select the desired memory limit from the list.
6. Wait for the change to automatically be saved.