WordPress.org

Ready to get started?Download WordPress

Forums

Can't edit .htaccess? (8 posts)

  1. A2JC4life
    Member
    Posted 2 years ago #

    When encountering memory errors, one of the common suggestions is to edit the .htaccess file to increase the memory allowance. But every time I add the suggested line to that file, I get errors trying to load the blog. (I've tried this on multiple servers now, with the same result.) Why is this?

  2. MickeyRoush
    Member
    Posted 2 years ago #

    A2JC4life wrote:

    When encountering memory errors, one of the common suggestions is to edit the .htaccess file to increase the memory allowance. But every time I add the suggested line to that file, I get errors trying to load the blog. (I've tried this on multiple servers now, with the same result.) Why is this?

    You're host may not have that module set up to be used with .htaccess. What directives (code) are you putting in your .htaccess?

  3. A2JC4life
    Member
    Posted 2 years ago #

    php_value memory_limit 64M

  4. MickeyRoush
    Member
    Posted 2 years ago #

    A2JC4life wrote:

    php_value memory_limit 64M

    If your host allows you to use php.ini files, try this format in your php.ini file:

    memory_limit = 64M

  5. Samuel B
    moderator
    Posted 2 years ago #

    or

    Try adding this line to your wp-config.php file:
    Increasing memory allocated to PHP
    define('WP_MEMORY_LIMIT', '128M');

  6. A2JC4life
    Member
    Posted 2 years ago #

    I've seen these, but they still don't answer the original question: why can I not add that to .htaccess without errors?

    (I don't have access to php.ini, by the way, and the wp-config edit has never seemed to have any effect.)

  7. MickeyRoush
    Member
    Posted 2 years ago #

    A2JC4life wrote:

    I've seen these, but they still don't answer the original question: why can I not add that to .htaccess without errors?

    (I don't have access to php.ini, by the way, and the wp-config edit has never seemed to have any effect.)

    It was stated here:

    MickeyRoush wrote:

    You're host may not have that module set up to be used with .htaccess. What directives (code) are you putting in your .htaccess?

    In other words this method will only work if PHP is running as an Apache module with your server. You'll have to refer to your host, as there are quite a few that are not set up like that.

  8. timDesain
    Member
    Posted 2 years ago #

    In some shared hosting, php_value memory_limit is restricted.
    so, you can't do that.
    contact your webhost.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.