I am very used to clicking the “Save and Continue Editing” button whenever I am in the midst of writing an article for this blog. Even though starting from WordPress version 2.1, it already has the auto-save function which happens in the background, it’s still a good practice to manually save because you might never know when it won’t work.
This happened while I was writing an article just now. Suddenly I got the error message “Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 163569 bytes) in /home/…/translator.php on line 0“. At first I thought it was the Translator plugin that was causing the problem. I moved the plugin to another location and still the same error. Later I noticed that I couldn’t get in to any part of Raymond.CC anymore. Forum don’t work, WordPress admin don’t work, not even the blog’s main page!
If all don’t work, it must be a problem on the server side. I did a little searching and luckily I found a solution to fix this problem without submitting a support ticket to my webhost.
The error message “Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 163569 bytes)…” indicates that some PHP scripts needed more memory than PHP was allowed.
You can fix the problem by increasing PHP’s memory limit in either way:
1. Try looking for php.ini file on the root of your site. Mine was located in public_html folder.
Open up php.ini file with any text editor and change the values for memory_limit. By default you should see memory_limit = 8M. Try changing it to 12M. If it doesn’t work, increase it to 16M or even 24M if 16M doesn’t work.

2. If you can’t find the php.ini file, open up the PHP file that requires more memory, and add a line below just after ini_set(‘memory_limit’, ’12M’);
Same thing. Memory can be increased but do try it with 12M first.
3. Final way is to look for .htaccess in your root, and add a line that looks like below.
php_value memory_limit 12M
Good luck in fixing the fatal error allowed memory size error.
Related posts:
nothing worked for me :((
thn man it is very usefull
THANK-YOU! Your solution was the one that worked when I got the error and my entire site disappeared!
That is so cool! My friend told me that is not true, well I’d better tell her about it.
Bonjour,
J’utilise la dernière version de WordPress et je me suis aperçu que j’ai presque atteint le quota imposé par Free pour ma base de données ! Pourtant le blog n’a qu’un seul article ! Certes j’ai des plugins installés mais je vois pleins de blog WordPress hébergés chez Free qui ont des archives de messages énormes datant d’un an ! Alors comment font-ils ? Si quelqu’un a eu le même problème aidez moi car je ne comprends pas ce que je doit faire ! Merci de me répondre par mail !
Thanks for this its first in google this is my problem in my blog thanks!
Thanks for the great tip. My host was kind enough to make the change to php.ini file for me.
thanks!!
thanks
True this is a quick fix to solve the problem without bringing down the whole WordPress blog site. This is definitely something wrong with the script which we have to voice out to the plugin’s author.
Granted this is a quick fix and for most scripts it should solve the problem.
However in my experience if a script is quickly running out of memory there is probably something wrong with the script. For example this error can happen when you have loops that append strings or arrays go out of control. It can also happen when manipulating huge amount of data. In this case it may be that then translator plug in is cloning the data every time it auto-saves. (Just a stab in the dark)
The configuration fix may alleviate the symptoms it may not really solve the problem which may be some bad interaction between WordPress and the plug-in or some bad code so this MAY come back to bite you in the future.
sorry to post again but 2 things id like to add
1 ) try the ajax save post plugin, helps a lot, saves without reloading page.
2 ) when i comment i get an error “Warning: session_start() [function.session-start]: Cannot send session cache limiter – headers already sent (output started at /home/raycc/public_html/blog/wp-content/plugins/SK2/sk2_second_chance.php:2) in /home/raycc/public_html/blog/wp-content/plugins/translator/translator.php(16) : eval()’d code on line 1″
You may edit this comment to remove the error. Thanks
nice tip raymond
congrats Raymond you very smart!!!