WHERE to add define('WP_MEMORY_LIMIT', '256M');"

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 56383 bytes) in /home/content/99/11123299/html/wp-includes/functions.php on line 251

Fatal error: Allowed memory size of
Dear Sir,

After I bulk activity a lot plugins,the systerm have fatal error.

I look over and over in wp-config.php not find define('WP_MEMORY_LIMIT', 'xxM' );
I tried to searching into that file but I found nothing!

Your support also not detal WHERE to add
define('WP_MEMORY_LIMIT', '256M');"
I tried add that line to WP-config.php,but after that the site have Internal Server Error

Please let me know detal WHERE to add.

Thank you!

67108864 bytes exhausted (tried to allocate 311296 bytes) in /home/content/99/11123299/html/wp-content/themes/blogs-mu/_inc/functions/options-functions.php on line 586
I add define('WP_MEMORY_LIMIT', '256M'); to that line, Is true? WHERE should to add.

I still need change anything?



* @package WordPress

define('WP_MEMORY_LIMIT', '256M');

// ** MySQL settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define('DB_NAME', 'a4h1314011274777');


  • Vaughan


    thanks for posting.

    that looks right where you have posted it.

    unfortunately, it isn't always possible to increase the memory.

    sometimes you can do it using htaccess

    add the following to your htacess file (at the top)
    php_value memory_limit 256M

    if you get an error after that, it may be that your PHP is configured in CGI or suPHP etc. in which case instead of htaccess, you should create a file called php.ini

    in the php.ini place this

    memory_limit = 256M

    if both of those fail, you should contact your host, they will be able to point you in the right direction, but it could ultimately be that your host will not allow you to change that setting.

    hope this helps.

  • hi999

    Dear Sir,

    I tried 3 place, but after that all have Internal Server Error or Fatal error: Allowed memory size of 67108864 bytes exhausted, please kindly let me know WHERE ,

    Thank you so much!


    * This file is used by the wp-config.php creation script during the
    * installation. You don't have to use the web site, you can just copy this file
    * to "wp-config.php" and fill in the values.
    * @package WordPress
    define('WP_MEMORY_LIMIT', '256M'); I ADD HEAR???
    // ** MySQL settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define('DB_NAME', 'a4h1314011274777');

    register_globals = off
    allow_url_fopen = off

    expose_php = Off
    max_input_time = 60
    variables_order = "EGPCS"
    extension_dir = ./
    upload_tmp_dir = /tmp
    precision = 12
    SMTP = relay-hosting.secureserver.net
    url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=,fieldset="

    ; Only uncomment zend optimizer lines if your application requires Zend Optimizer support


    ; -- Be very careful to not to disable a function which might be needed!
    ; -- Uncomment the following lines to increase the security of your PHP site.

    ;disable_functions = "highlight_file,ini_alter,ini_restore,openlog,passthru,
    ; phpinfo, exec, system, dl, fsockopen, set_time_limit,
    ; popen, proc_open, proc_nice,shell_exec,show_source,symlink"
    memory_limit = 256M I ADD HEAR???


    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    php_value memory_limit 256M
    ______________________________I ADD HERE??
    # add a trailing slash to /wp-admin
    RewriteRule ^wp-admin$ wp-admin/ [R=301,L]

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]
    # BEGIN wtwp_cache
    <IfModule mod_mime.c>

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.