Support » Plugins » Clean URLs and .htaccess

  • Hello. I’m trying to get clean urls to work with my installation of WordPress.

    My permalink structure is:


    My .htaccess file contains:

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.+)$ /index.php/$1 [L,QSA]

    And it works great for articles. The problem is that when I try to access archives, categories or tags (, it generates a 404 error, since it’s interfering with the article redirect. Pages seem to work fine though. How do I tell mod_rewrite NOT to rewrite the URL if it’s a category, tag or archive link? I can’t seem to find any documentation or web page clearly documenting how to do this…


Viewing 1 replies (of 1 total)
  • whooami



    thats what ! is for 🙂

    for instance,

    RewriteCond %{REMOTE_ADDR} =
    RewriteCond %{REQUEST_URI} !/idiot\.php$
    RewriteRule \.php$ [R=301,L]

    will apply the rewrite rule to every page except idiot.php

    its used in the example above to prevent looping.

Viewing 1 replies (of 1 total)
  • The topic ‘Clean URLs and .htaccess’ is closed to new replies.