We have installed WordPress on Sub domain and We have added https to the subdomain, but when we login into wp-admin we are getting Sorry, you are not allowed to access this page this error.
We did some changes in wp-config file to force the https.

wp-config.php

define('FORCE_SSL_ADMIN', true);
define('FORCE_SSL_LOGIN', true);
$_SERVER['HTTPS']='on';

DB changes:

Siteurl - http://blog.site.com to https://blog.site.com
home    - http://blog.site.com to https://blog.site.com

Read more here: How to resolve Sorry, you are not allowed to access this page in wordpress?


Solution:

If you know the solution of this issue, please leave us a reply in Comment section, to update the question.


Wordpress related questions and answers: