Looks like with no warning, allowable memory for PHP went from something that worked to 8 megs. I’ll finish fixing my site when I get back to NH from Christmas.
SUCK
Looks like with no warning, allowable memory for PHP went from something that worked to 8 megs. I’ll finish fixing my site when I get back to NH from Christmas.
SUCK
Sponsor
3 Comments
I noticed that. I’m assuming you’re on a shared server, I have to wonder if someone on the same server wrote some code with a memory leak in it.
Hmm…but if they have a hard cap of memory per site it could mean the memory leak is on your side? But the entire point of newer scripting languages is that garbage collection is done server-side.
My PHP book is sitting on the shelf at work, but it looks like to manually free up the memory you can use the unset(); function for your variables and session_unset();
session_destroy(); for any session variables.
Toss a function at the end of your scripts and see if the problem goes away. That’s Dave’s troubleshooting with minimal knowledge of PHP and not looking at your code at all. Use that information to calibrate the grain of salt you want to take the advice with ;-)
Thanks Dave! I’ll take a look at it when I’m not with family for Christmas.
Post a Comment