WordPress.org

Ideas

Less draconian htaccess rules for pretty permalinks

  1. vanishdesign
    Member

    I'd love if my permalinks were controlled by my htaccess file and my htaccess wasn't configured to send every wrong URL to wordpress's custom rewriter. I don't want my 404 page controlled by my WordPress theme.

    I am really banging my head against the wall trying to get normal rewrite rules to work with wordpress. I want to switch my http://www.domain.com to domain.com for instance. I want to use rewrite rules in a part of my site that's not wordpress. I want control of my site back. I like WordPress, but it's overbearing in this area. Thanks.

    Posted: 6 years ago #
  2. Andy Macaulay-Brook
    Member

    12345

    Why not just add your own rules to .htaccess?

    Posted: 5 years ago #
  3. Ipstenu (Mika Epstein)
    Half-Elf Support Rogue, Volunteer Forum Mod & Plugin Referee

    So long as you put your .htaccess code BEFORE the WP code, this all works. I do that myself (including re-directing 404s).

    # Getting rid of the WWW in front
    RewriteCond %{HTTP_HOST} ^www.domain.com [NC]
    RewriteRule ^(.*)$ http://domain.com/$1 [L,R=301]
    Posted: 5 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.

  • Rating

    12345
    2 Votes
  • Status

    Sorry, not right now