WordPress.org

Ready to get started?Download WordPress

Forums

Htaccess : How To Redirect https to http ignoring one folder (1 post)

  1. Earthorg
    Member
    Posted 3 years ago #

    Hi my friends,

    I just tried to add the following htaccess rules to redirect all https urls (www and non www) (except /wp-admin folder and everything inside it) to http (non www). But when its added, it started to give me redirection loops! Know why its happening?

    PS : Im also using w3Total Cache plugin and it have a lot of rewrite rules

    RewriteEngine On
    RewriteBase /
    RewriteCond %{HTTPS} on
    RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
    RewriteRule ^(.*)$ http://%1/$1 [R=301,L]

    RewriteCond %{HTTPS} on
    RewriteCond $1 !^wp-admin/
    RewriteRule ^(.*)$ http://techhamlet.com/$1 [R=301,L]

    Thanks

Topic Closed

This topic has been closed to new replies.

About this Topic