Fatal Error

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Snowman872
    Member
    • Feb 2005
    • 51
    • 3.5.x

    Fatal Error

    I'm getting a fatal error on one particular thread when I try to view it. Strangely, other threads do not seem to have this problem, although I imagine some could have this problem and I am unaware of it.

    Fatal error
    : Allowed memory size of 8388608 bytes exhausted (tried to allocate 228830 bytes) in /home/xxxxx/public_html/xxxxxx/includes/functions.php(5571) : eval()'d code on line 50

    That seems like a very large amount of memory it is trying to allocate. There's nothing real special about that thread that I am aware of.
    Also, I just noticed for the first time, when I tried to search for that thread, using some search terms in that thread title, I got this error:

    Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 35 bytes) in /home/xxxxx/public_html/xxxxxxx/search.php on line 1151

    I never had this problem in the past but did recently have the PHP upgraded from version 4 and MySQL upgraded to 5. The server is running Apache v1.3.41 (cgi), PHP 5.26, MySQL 5.0.51a-community. PHP memory limit is 8MB. The forum is relatively small, with about 60 users on at one time and 66,000 messages.

    Assistance would be appreciated.
  • Steve Machol
    Former Customer Support Manager
    • Jul 2000
    • 154502
    • 5.7.5

    #2
    Your PHP does not have enough memory allocated to it to complete this operation. Ask your host to increase the 'memory_limit' variable in php.ini to at least 32M.

    To temporarily up your limits edit your includes/config.php file and add these lines right under the <?php line:

    ini_set('memory_limit', 32 * 1024 * 1024);

    Also, that specific error is from an add-on. But increasing the memory_limit is a good idea anyway.
    Steve Machol, Founder of the OptiBoard Discussion Forums for Eyecare Professionals

    Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.

    Comment

    • Snowman872
      Member
      • Feb 2005
      • 51
      • 3.5.x

      #3
      Originally posted by Steve Machol
      Also, that specific error is from an add-on. But increasing the memory_limit is a good idea anyway.
      Thanks Steve, I do have some add ons, but I really have no idea which one might be causing the problem. I looked in "functions.php" for some hints, and line 50 did not provide any clues to me. It's a comment line.

      define('COOKIE_SALT', 'xxxxx');

      // #############################################################################
      /**
      * Essentially a wrapper for the ternary operator.
      *
      * @deprecated Deprecated as of 3.5. Use the ternary operator.
      *
      * @param string Expression to be evaluated
      * @param mixed Return this if the expression evaluates to true
      * @param mixed Return this if the expression evaluates to false
      *
      * @return mixed Either the second or third parameter of this function
      */
      function iif($expression, $returntrue, $returnfalse = '')
      {
      return ($expression ? $returntrue : $returnfalse);
      }

      // #############################################################################
      Line 50 is below the "@ return".
      Last edited by Zachery; Tue 14 Oct '08, 1:40am.

      Comment

      • Snowman872
        Member
        • Feb 2005
        • 51
        • 3.5.x

        #4
        The temporary fix does allow me to see the thread again. I'll have the changes made to the php.ini file.

        I'd still like to find the offending add on.

        Comment

        • Zachery
          Former vBulletin Support
          • Jul 2002
          • 59097

          #5
          functions.php(5571) : eval()'d code on line 50

          The error is on functions.php line 5571, and line 50 of the code in that plugin.

          Comment

          widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
          Working...