0
votes

I am working on a site using localhost. Some where I have messed up a setting and when I try to open my wp-admin site it is putting localhost at the beginning of my path names.

ex. when I try to go to localhost/wp-admin it redirects me to http://localhost/wp-admin/localhost/wp-login.php?redirect_to=http%3A%2F%2Flocalhost%2Fwp-admin%2F&reauth=1

I have tried renaming .htaccess file, updating siteurl & home tables in phpmyadmin back to localhost.

3
go in wordpress options table and look for siteurl and home, see if they are localhost, @AdamSeymoad - Parth Mahida
They are. That was the first thing that I tried. - Adam Seymoad
There are a few other things that are happening too. I noticed on some of my image paths it is appending localhost to the front of the path as well when trying to echo the stylesheet path. - Adam Seymoad

3 Answers

0
votes

Well I had the same problem yesterday just after installing Wordpress. Check in your host cPanel if varnish caching has been enabled. If so, go ahead and disable it. Wait for 30 minutes and then try logging in.

0
votes

It look like in DB siteurl & home tables site URL added 2 times by mistake. review that table again.

0
votes

For me i had 127.0.0.1 local.se set in /etc/hosts and in my DB siteurl & home tables local.se it was supposed to be http://local.se