I've enabled SSL for my main domain but i want to enable it fully for my wordpress website which is located in a subfolder. when i say fully i mean in admin area and the website itself and without any mixed content error.

so first i tried adding these in wp-config:

/* Enable SSL Encryption */
define(‘FORCE_SSL_LOGIN’, true);
define(‘FORCE_SSL_ADMIN’, true);

it resulted in getting mixed content error and "You do not have sufficient permissions to access this page" error after login to the dashboard. i got the same error when i tried to change the blog url and website url in settings. then i used plugins like "https-ssl", "fix mixed content". they didn't do anything good for me either. i'm looking for a way to make that happen

  • In the options did you set the blog URL and home URL to https://... too? – Jörn Lund Oct 6 '14 at 12:43
  • yes i forgot to mention that, after that i got the same error that said "you do not have sufficient permissions". then i used phpmyadmin to access the database to change those addresses back to http version – Conspiria Oct 6 '14 at 13:47
  • After changing it to SSL, try to clear your cookies and then log in again. You won't be able to access the new SSL pages with your old auth cookies. – Otto Oct 6 '14 at 15:04
  • i did that but no luck. the website loads over https but i get this error all over the browser console "Resource interpreted as Image but transferred with MIME type text/html:" – Conspiria Oct 6 '14 at 15:31
up vote 4 down vote accepted

I had the same problem and solved it by moving the two define statements up before the require_once that includes wp-settings.php. Seems this was the issue all along.

Source: https://stackoverflow.com/a/27193576/117268

  • I had found another workaround for that but i just tested your method on an offline example and so far it works very well, i will use it online too, thank you! – Conspiria Mar 1 '15 at 15:56
  • This saved me from another 4 hours of debugging. Thank you! – andersevenrud Jan 12 '17 at 13:37

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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