0

I've made some changes so the blog will work using SSL (https://) but now I cannot access my blog anymore - every time I try to access it I'm redirected to https://example.com, eventhough I try to acess to http://example.com.

I can fix it if by adding this two lines to the wp-config.php file:

define( 'WP_HOME',    'http://example.com' );
define( 'WP_SITEURL', 'http://example.com' );

But I can't use SSL using this fix. Why am I redirected automatically to the https:// when I want to access the blog through http://? How can i change it back?

0

I believe generally, a website is either secure (SSL), or it's not. If you needed to activate SSL for a portion of your website, you should keep it all as https://. There is no drawback to doing so. If anything, it will give people more confidence in your website.

Those 2 links you have mentioned override database defaults. There are 2 ways to set them:

With Database/phpMyAdmin access - go into the wp_options tables, and change the site_url (entry 1) and home (entry 36) values, just remove the s.

Without Database Access - put the following line into your wp-config.php file, access http://domain.com/wp-login.php directly, not using /wp-admin. Log into the site, then remove this line.

define( 'WP_REDIRECT', true );

You could also just leave those 2 lines in the config file. They won't hurt anything except for when you try pulling the site to another domain/staging server.

  • See updated answer for 2 ways to change the protocol in your site. – Eric Holmes Sep 8 '14 at 16:04
  • I don't have DB access. I tried putting define( 'WP_REDIRECT', true ); directly in the wp-config.php, instead of the 2 lines and it didn't work. I'm Still redirected automatically to the https:// address so i can't access the http://. I would have kept the 2 lines but i want to work with SSL in the future. – user3623969 Sep 8 '14 at 16:22
  • If you want to work with SSL in the future, just take them out when you are ready. You're pretty limited without DB access at this point. – Eric Holmes Sep 8 '14 at 16:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.