NotePad, by default wraps text. You don't want this when copying this script code to it. Word Wrap has been known to put unwanted spaces in code and this could cause issues when you upload the finished text file to your root directory and try to use it..
Do this first...
1. Open NotePad. Click on "Format."
2. Uncheck "Word Wrap"
Now, copy the file to your clipboard.
The file is located at the bottom of the page here...
http://codex.wordpress.org/User:MichaelH/Orphaned_Plugins_needing_Adoption/Emergency
Past it into NotePad and name it...emergency.php
Upload this file to the root directory as previously instructed.
Open a browser window and put your domain with the filename in the address bar. It should look like this:http://yoursite.com/emergency.php
Open it and this is what you are going to get...
This is pretty self-explanatory. Follow the instructions given and BINGO! You should now be able to get into your Admin area!
Once you are able to get in okay, one last and VERY important item...
Be sure to remove the script from the root directory when you are done! Note that anyone can use this script to change your password, so DO remember to delete it when you are finished using it.
I hope this tutorial helped. I've used this method a couple times. If password retrieval using your browser's stored passwords area doesn't do the job, this is the thing to do, even if it is a last resort.
Daniel
I do like telling Chrome to save my passwords, so if I have to I can use its retrieval list in the chrome menu . I realize there's a security problem inherent in doing this. (If I can access this menu, so can anyone who gets access to my computer. Far too easy.) So I am careful about what sites I let Chrome save passwords for.
Second, I do the send-myself-an-email trick for each user/password combo. I collect them in an oh-so-cleverly-named file. And I think I am so very clever when I just say in the email, follow algorithm. i hope my attempts at being sufficiently paranoid are never tested.
Thirdly, the algorithm itself. I never write it down anywhere, It's my own and I better never forget what it is. It does let me generate a password that is unique to each site. And i guess I could recreate it by looking at some of the passwords I have asked Chrome to save.
Fourth, when a site gives me an impossible-to-remember password, I go in and change it to my algorithm.
Last but not least, banking sites are an exception to all above rules.
And oh dear, just writing this makes me feel paranoid !