I recently installed SSL certificate for my wordpress site(http to https) and now I'm unable to access Wordpress Admin. It refreshes the page and I am not logged in.
Is there something I forgot to change in my wordpress files?
I inspected the code and the login form is pointing to my old site (the http one) and when I look at the code in the file, the form action is set to site_url() and I can't seem to find where it's defined.
Go to phpadmin and find wp-options. Change siteurl and home to http. Its work :)
I went to the cpanel>filemanager and edit the file wpconfig.php inside php tags i added if (strpos($_SERVER['HTTP_X_FORWARDED_PROTO'], 'https') !== false) $_SERVER['HTTPS']='on';
It is possible to set the site URL manually in the wp-config.php file.
Add these two lines to your wp-config.php, where "example.com" is the correct location of your site.
For more refer here
or check in table
wp_options
columnoption_name = siteurl
check theoption_value
You need to change the site url in wp-admin->Settings->General. Except now you need to go in through phpMyAdmin and do it manually in the
wp_options
table since you are locked out.You get different cookies depending on http/https so you are getting the https cookie and then being redirected to http that has no cookie because of your Wordpress settings that say what url the site resides at.
I had the exact same problem with my site on NearlyFreeSpeech.net, and the solution was not so simple as fixing the site URLs. That made no difference.
The underlying problem in my case, and the solution, were explained in the post copied below. Note that on my system, the SSL error created two problems, the one described here on Stack Overflow (wp-login refreshes without logging in) and a failure of WP to load stylesheets, which was the problem actually addressed in the forum post quoted below. The solution in the post solves both problems.
I have used this first:
i have
still not able to fix and nothing happened.
Then I used
and I was able to connect to wp with https.
Now I have only minor issues of conflict (mixed https/http content on my page) but most things work.
Thank you!