Fatal error: Allowed memory size »  Show posts from    to     

Icy Phoenix


Old Docs - Fatal error: Allowed memory size



travagghio [ Fri 08 Dec, 2006 18:13 ]
Post subject: Re: Fatal Error: Allowed Memory Size
Dear Mighty Gordon,
I follow all for a long time your councils and can define yours fan.
I have a problem that it is making me to drive crazy.
I have aphpbbplus forum, and a category of the same one is opened the anonymous users.
Unfortunately, by little time, when I want to visualize IP address of the anonymous users who has sent a topic, I receive this message

Fatal error: Allowed memory size of 12582912 bytes exhausted (tried to allotted 35 bytes) in /web/htdocs/.../.../includes/functions.php on linens 804

The forum is on "hosting Aruba". I have tried the things advised in this and the other message, but they are not successful. Is there a solution?

Sincerely yours, Vincenzo


Mighty Gorgon [ Fri 08 Dec, 2006 18:28 ]
Post subject: Re: Fatal error: Allowed memory size
Vincenzo, thank you for translating your request in english.

As I said you can get Italian support on other sites... but if you prefer we can continue here.

First, I don't know much about Plus... but I'll try to help you anyway.

Did you get that warning only when clicking the IP button?

If yes, and if the error is always the same, can you post here lines from 790 to 820 or your functions.php please?

You can use CODE BBCode specifying starting and highlighting params (help in BBCodes Glossary topic!).

Try also inserting this code on top of your common.php:

Code: [Hide] [Select]
ini_set("memory_limit", "16M");


travagghio [ Fri 08 Dec, 2006 22:21 ]
Post subject: Re: Fatal Error: Allowed Memory Size
Thank you, master menthor!

You have solved my existential problem! :mryellow:!!!

I confirm to be your fan! You are the best!

I don't know if you asked to me code line 790-820 from "function.php" for

preventing this problem in the future and for others users, or only for helping me.

In doubt, I paste the lines:

//790
}
}

return $row;
}

function encode_ip($dotquad_ip)
{
$ip_sep = explode('.', $dotquad_ip);
return sprintf('%02x%02x%02x%02x', $ip_sep[0], $ip_sep[1], $ip_sep[2], $ip_sep[3]);
}

function decode_ip($int_ip)
{
$hexipbang = explode('.', chunk_split($int_ip, 2, '.'));
return hexdec($hexipbang[0]). '.' . hexdec($hexipbang[1]) . '.' . hexdec($hexipbang[2]) . '.' . hexdec($hexipbang[3]);
}

//
// Create date/time from format and timezone
//
function create_date($format, $gmepoch, $tz)
{
global $board_config, $lang;
static $translate;

if ( empty($translate) && $board_config['default_lang'] != 'english' )
{
@reset($lang['datetime']);
while ( list($match, $replace) = @each($lang['datetime']) )
{
//820

Really great thanks!!!

Nun ti siddiare per il mio inglese! Salutamo dalla Sicilia!!!


Mighty Gorgon [ Tue 12 Dec, 2006 01:43 ]
Post subject: Re: Fatal error: Allowed memory size
You're welcome...

Thanks for posting the code, but I need some testing to verify that function... In the meantime, I'm glad you solved.




Powered by Icy Phoenix