Title: htaccess file problem
Last modified: August 20, 2016

---

# htaccess file problem

 *  [mariobarba](https://wordpress.org/support/users/mariobarba/)
 * (@mariobarba)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/htaccess-file-problem-5/)
 * Hi
    If I select any permalinks other than the default it corrupts my htaccess
   file & then I cant login to the site after that.
 * My server host said this:
    The default .htaccess rule set for WordPress is:
 * —
    <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME}!-
   f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule
   > —
 * The issue was that, the rewrite rules to redirect translationdoctor.co.uk to 
   [http://www.translationdoctor.co.uk](http://www.translationdoctor.co.uk) in your
   main .htaccess file as shown below:
 * —
    #RewriteCond %{HTTP_HOST} . #RewriteCond %{HTTP_HOST} !^www\.translationdoctor\.
   co\.uk [NC] #RewriteRule (.*) [http://www.translationdoctor](http://www.translationdoctor)\.
   co\.uk/$1 [R=301,L] —
 * and the option to disable/enable various permalink options in WordPress admin
   panel is conflicting, because of which WordPress ends up erasing the default 
   rules for its own .htaccess file (wp/.htaccess), making the blog inaccessible.
   As of now, I have disabled the www redirect by commenting out the above rules,
   and everything is working fine now.
 * To be able to use both the options, you will need to seek assistance from WordPress.
   ——————-
 * Can you help?

Viewing 1 replies (of 1 total)

 *  [Sugar Apple](https://wordpress.org/support/users/blacklizt/)
 * (@blacklizt)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/htaccess-file-problem-5/#post-2952544)
 * > #RewriteCond %{HTTP_HOST} !^www\.translationdoctor\.co\.uk [NC]
   >  #RewriteRule(.*)
   > [http://www.translationdoctor](http://www.translationdoctor)\.co\.uk/$1 [R=
   > 301,L]
 * remove the backslashes. so it will be:
 * > #RewriteCond %{HTTP_HOST} !^www.translationdoctor.co.uk [NC]
   >  #RewriteRule (.*)
   > [http://www.translationdoctor.co.uk/$1](http://www.translationdoctor.co.uk/$1)[
   > R=301,L]
 * *) Based on my site .htaccess, i find no backslashes for site redirect.

Viewing 1 replies (of 1 total)

The topic ‘htaccess file problem’ is closed to new replies.

## Tags

 * [htaccess](https://wordpress.org/support/topic-tag/htaccess/)
 * [permalinks](https://wordpress.org/support/topic-tag/permalinks/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [Sugar Apple](https://wordpress.org/support/users/blacklizt/)
 * Last activity: [13 years, 9 months ago](https://wordpress.org/support/topic/htaccess-file-problem-5/#post-2952544)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
