WordPress.org

Ready to get started?Download WordPress

Forums

Redirect WWW to without while Ignoring HTTPS (1 post)

  1. shane1800
    Member
    Posted 2 years ago #

    Hi,

    In my htaccess file I have this which redirects visitors from http://www.shanestaats.com to shanestaats.com. This is much faster than letting wordpress do it.

    Problem is when I go to login to admin I get redirect loops.

    Anyone know how to say ignore rewrite if https?

    # Faster redirect from www to without www
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{HTTP_HOST} !=shanestaats.com [NC]
    RewriteRule ^(.*)$ http://shanestaats.com/$1 [R=301,L]
    </IfModule>
    # END Redirect

Topic Closed

This topic has been closed to new replies.

About this Topic