How I Logged Back into WordPress After Locking Myself Out
One problem with doing any task over and over is that your attention tends to wander a bit after the process becomes too familiar.
I noticed this the other day when I was setting up a new WordPress installation. This is something I have done many times before. But this time I somehow got turned around when setting up the options. I managed to change the WordPress URL to point to an invalid URL. (I had intended to change the “Front page displays” option, but got confused. One problem with the WordPress administration screens is that its options do all tend to look similar.)
This was a big problem because WordPress was now convinced that it was actually installed at that invalid URL. Not only did the site no longer display, but WordPress kept trying to route me to that invalid URL whenever I tried to log in. If I couldn’t log in, how could I change the URL back to the correct value?