Forums

.htaccess permissions (3 posts)

  1. Zalethon
    Member
    Posted 3 years ago #

    So I just installed WordPress on a server I own, as something to do and work with. I've been trying to get pretty permalinks to work since then, and having little luck... We'll get to the meat of that later, though. Maybe in another post.

    The very first problem I encountered, which I worked around in a less-than-optimal way, was that wordpress couldn't edit .htaccess. Or, for that matter, wp-config.php.

    It still can't, actually. I started over from scratch, though I left the SQL database intact. .htaccess has its permissions set to 644 at the moment. I own the directory, (public_html) and I installed WordPress, so I'm thinking it should work. But for WordPress to edit the file, I had to give the world write access. Or at least, those who aren't me or my group.

    Any ideas what the problem might be, and how to fix it?

  2. Shane G
    Member
    Posted 3 years ago #

    Hi,

    Please set 766 permissions to htaccess file and set the permalinks to your requirement..once you do that it should be resolved..

    Also check this code is added in htaccess:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    Thanks,

    Shane G.

  3. Zalethon
    Member
    Posted 3 years ago #

    ... Well, that worked. Thank you, very much!

    I don't suppose you, or someone else, might have any explanation as to why this didn't work before? I had managed to get wordpress to write the .htaccess file by setting permissions to 777, but even then permalinks wouldn't work right. If I should know why they didn't work, I don't. I am very new to this.

    Permalinks work fine, now. (Even after I reverted permissions to 644)

Topic Closed

This topic has been closed to new replies.

About this Topic