Title: backend http to https random redirection
Last modified: August 21, 2016

---

# backend http to https random redirection

 *  Resolved [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/)
 * While editing or writing a new post, sometimes I get redirected to the following
   address:
    [https://www.examplesite.com/wp-login.php?redirect_to=https://www.examplesite.com/wp-admin/edit.php&reauth=1](https://www.examplesite.com/wp-login.php?redirect_to=https://www.examplesite.com/wp-admin/edit.php&reauth=1)
   even though i wasn’t navigating using https. We don’t have an SSL certificate
   for our domain, so we get the following warning message: “There is a problem 
   with this website’s security certificate.” [https://dl.dropboxusercontent.com/u/44483749/https_error_redirection.JPG](https://dl.dropboxusercontent.com/u/44483749/https_error_redirection.JPG)
 * We are using WP MultiSite version 3.7.1 and it happens on the primary domain(
   haven´t testes over teh others yet). It is a random thing…
    .htaccess file has
   0755 permissions wp-config.php file has 0755 permissions with the following info:
 *     ```
       define('WP_DEBUG', false);
       define('WP_ALLOW_MULTISITE', true);
       define( 'MULTISITE', true );
       define( 'SUBDOMAIN_INSTALL', false );
       $base = '/';
       define( 'DOMAIN_CURRENT_SITE', 'www.examplesite.com' );
       define( 'PATH_CURRENT_SITE', '/' );
       define( 'SITE_ID_CURRENT_SITE', 1 );
       define( 'BLOG_ID_CURRENT_SITE', 1 );
       define('WP_ALLOW_REPAIR', true);
       define('FORCE_SSL_LOGIN', false);
       define('FORCE_SSL_ADMIN', false);
       ```
   
 * After getting the warning message, if you clic continue, the browser will take
   you to the login page and after inserting credentials correctly, you are taken
   to the post edition page but now you are navigating with the https..
 * How can i prevent the random https login redirection?

Viewing 9 replies - 1 through 9 (of 9 total)

 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580334)
 * There’s no redirect in your .htaccess righjt?
 *  Thread Starter [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580345)
 * Here is the .htaccess:
 *     ```
       # BEGIN W3TC Browser Cache
       <IfModule mod_deflate.c>
           <IfModule mod_headers.c>
               Header append Vary User-Agent env=!dont-vary
           </IfModule>
               AddOutputFilterByType DEFLATE text/css text/x-component application/x-javascript application/javascript text/javascript text/x-js text/html text/richtext image/svg+xml text/plain text/xsd text/xsl text/xml image/x-icon application/json
           <IfModule mod_mime.c>
               # DEFLATE by extension
               AddOutputFilter DEFLATE js css htm html xml
           </IfModule>
       </IfModule>
       # END W3TC Browser Cache
   
       AddHandler php5-script .php
   
       php_value memory_limit 300M
       php_value max_execution_time 0
   
       # BEGIN WordPress
       <IfModule mod_rewrite.c>
       RewriteEngine On
       RewriteBase /
       RewriteRule ^index\.php$ - [L]
   
       # uploaded files
       RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
   
       # add a trailing slash to /wp-admin
       RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
   
       RewriteCond %{REQUEST_FILENAME} -f [OR]
       RewriteCond %{REQUEST_FILENAME} -d
       RewriteRule ^ - [L]
       RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
       RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
       RewriteRule . index.php [L]
   
       </IfModule>
   
       # END WordPress
       ```
   
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580392)
 * Check on a different browser.
 * Also delete all the cookies for that domain and log back in. See if that forces
   it around.
 *  Thread Starter [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580546)
 * I deleted cookies, temporary files, etc and tried it in different computers, 
   browsers and operating systems and the final result is the same. It is still 
   happening.
    I guess is something related to the theme, css, js… Sometimes the
   website doesn’t load properly…
 * Do you know where I can check the errors of my template while loading?
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [12 years, 4 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580547)
 * Turn on Debugging: [https://codex.wordpress.org/Debugging_in_WordPress#WP_DEBUG](https://codex.wordpress.org/Debugging_in_WordPress#WP_DEBUG)
 * Also I’d check the server error logs. Maybe a server setting is prompting the
   redirect.
 *  Thread Starter [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580570)
 * I will turn on the debugging feature soon. Before doing that I want to say that
   I have 3 more blogs under the same network and they have the same issue.
    While
   navigating through wp-admin, you get the message that says that the content isn’t
   secure and the SSL certificate doesn’t belong to current domain (because I’m 
   getting redirected to https and i’m not using a certificate for my domain). Saying
   that, I guess there is a problem with the server of the hosting company. It’s
   a shared hosting. I’m planning to build a development environment to test it 
   with a duplicate of the site. I’ll tell you what happened…
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [12 years, 3 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580574)
 * >  It’s a shared hosting.
 * That’s a bad idea. Multisite doesn’t play great on Shared. SSL plays even worse.
 *  Thread Starter [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580575)
 * That explains a lot of issues. I will get a VPS!!!
 *  Thread Starter [xalj](https://wordpress.org/support/users/xalj/)
 * (@xalj)
 * [12 years ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580620)
 * The redirection was caused by MT’s shared hosting: Grid Service.
    We moved to
   a VPS with another hosting company and the random redirection stopped instantly.
   Thanks for your help.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘backend http to https random redirection’ is closed to new replies.

## Tags

 * [edit.php](https://wordpress.org/support/topic-tag/edit-php/)
 * [HTTP](https://wordpress.org/support/topic-tag/http/)
 * [HTTPS](https://wordpress.org/support/topic-tag/https/)
 * [redirect_to](https://wordpress.org/support/topic-tag/redirect_to/)
 * [wp-admin](https://wordpress.org/support/topic-tag/wp-admin/)
 * [wp-config](https://wordpress.org/support/topic-tag/wp-config/)
 * [wp-login.php](https://wordpress.org/support/topic-tag/wp-login-php/)

 * In: [Networking WordPress](https://wordpress.org/support/forum/multisite/)
 * 9 replies
 * 2 participants
 * Last reply from: [xalj](https://wordpress.org/support/users/xalj/)
 * Last activity: [12 years ago](https://wordpress.org/support/topic/backend-http-to-https-redirection/#post-4580620)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
