Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where to edit for increase in memory in PHP ini file?

Tags:

php

Hi I do have a PHP script which reads text file. when text file size is above the certain limit script gives error and stops. when I divide files into two it works. so where is that settings in PHP to increase read file memory?

like image 767
mathew Avatar asked Dec 06 '22 23:12

mathew


1 Answers

The setting is memory_limit and you can change it in the php.ini file for all scripts, or (better) just change it in the code for the one script that is causing you problems:

ini_set('memory_limit', '64M');
like image 190
Eric Petroelje Avatar answered Dec 10 '22 13:12

Eric Petroelje