I have changed this:
wp_redirect( esc_url_raw( 'https://' . $_SERVER['SERVER_NAME'] . '/' . $_SERVER['REQUEST_URI'] ), 301 );
To this:
wp_redirect( esc_url_raw( 'https://' . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI'] ), 301 );
Because the URL it created contained double slash.
Example https://www.domain.com//contact.
So after removing '/'
from the url it works fine.
From PHP docs I understand that REQUEST_URI already contains the slash:
https://es.php.net/manual/en/reserved.variables.server.php
‘REQUEST_URI’
The URI which was given in order to access this page; for instance, ‘/index.html’.
Hi Ian,
Thanks for this plugin. I installed it with the latest version of WP but the redirect isn’t working I’m afraid.
If you go to https version of https://www.atlasandboots.com, you’ll see that it does not redirect to http.
Note that I tried adding define(‘FORCE_SSL_ADMIN’, true); to my wp-config file just to see if that helps but a) it still didn’t force http and b) it wouldn’t let me into the admin and login areas even though they were defined as exceptions. I have now taken that line out of the wp-config file.
Are you able to help at all please? This is making me tear my hair out! Finally, I have W3 Total Cache installed. I tried deactivating it in case it was messing things up but it had no effect.
Thanks,
Kia
]]>Hi
Firstly thank you for your work on your plugin. It’s working great for me.
I am having problems where Google is ranking my pages as https and I don’t want this. Your plugin is now redirecting all https to http which is great.
My question is:
How is the redirection working? Is it a permanent 301 redirect that will satisfy google and therefore encourage google to reindex all of my https pages to http.
Please can you confirm?
Thank you.
]]>Hi, how are you? English
I have a question.
This plugin works to allow some pages use HTTPS and not others? My site has SSL but I want to use only on the login page.
Hola! Cómo estás? Spanish
Tengo una pregunta.
Este plugin funciona para permitir que algunas páginas utilizan HTTPS y no otros? Mi sitio tiene SSL pero quiero usar sólo en la página de inicio de sesión.
Oi, como vai? Portuguese
Estou com uma dúvida.
Este plugin funciona para permitir que algumas páginas usem HTTPS e outras n?o? Meu site possui o SSL mas eu quero usar somente na página de login.
I’ve got this set up on WP 3.9.2 and in the exceptions box I have:
wp-admin
wp-login
If I go to https://mydomain.com/ in Firefox, it correctly rewrites as https://mydomain.com/
But if I go to https://mydomain.com/ in some browsers (Safari, Chrome, Seamonkey) it tries to display the https site, which is broken.
Shouldn’t this be happening at the server level rather than at the browser level?
]]>When I installed this plugin, the site randomly started throwing off too many redirect errors. It didn’t happen all the time, so I wasn’t able to duplicate the problem, but after disabling the plugin, it seems like the issue went away.
]]>I just tried installing the plugin and it hasn’t changed anything. I looked through some of the other threads but didn’t find a solution. I have no exceptions listed because I don’t use SSL anywhere on my site. For whatever reason there are scattered https links on my site and many have been linked onto Pinterest that way, meaning that even if I change all of the incorrect links on my site people will still get errors trying to visit my site. I definitely need something that will forward all https links to http.
Any ideas on how to get the plugin to work for me? Note: I am not very tech savvy which is why I’m trying to use a plugin to begin with. I am using the latest version of WordPress, 3.9.
Thank you!
]]>We are on the latest version of wordpress but google is crawling some of our pages as HTTPS. We do not want to use a mod rewrite because we do pull some images and scripts via SSL. Also we DO want to be able to access admin via SSL only.
Will your plugin work for this?
]]>I am using this and it doesn’t seem to be working. When I go to https://bombbomb.com/blog, it stays at https.
]]>Hi
We have had SSL and now we have not more.
A lot of our Website links are extern posted with HTTPS;
So we would like to “redirect” now to HTTP;
We installed Plugin “Force non-SSL”; but until now,
nothing happened, no any results.
Any ideas?
Thank you in advance!
Regards,
Rado
https://www.newcameraclub.com
Was having the classic WP problems with SSL and this did the trick. The only issue that remained was automatically forcing SSL for a specific page. I was able to do that on my own without having to links all over my site.
I like the idea of globally limiting all front end pages and trimming back from there. I think you’re on to something with this one. 5 Stars from me. ??
Feature request: Rather than just making SSL okay on specific pages, provide a check box to force it on specific pages… Then you’ll have the winner!
Thanx again and best wishes.
]]>I just installed and activated the plugin, but no options appear in my General Settings screen. Looks like this could be just what I need. Any help is appreciated. ??
]]>This plugin works on my WP multisite installation with FORCE_SSL_ADMIN enabled.
My reason for using this is the Facebook Like button. When enabled it differs on http and https, so it is usefull to force http.
]]>