[resolved] Login Problem (4 posts)

  1. rcmullins
    Posted 9 years ago #

    I have a unique problem. I was messing around with MySQL and decided to try changing my admin login password using MySQL. Here is the query I used.
    UPDATE wp_users SET user_pass = PASSWORD('mypass') WHERE ID = 1;

    It worked beautifully. Only problem is, that I cannot login now. I am using wordpress on the standard apache 2, php5, MySQL 5 set up. Anybody have any ideas on how to get around this? (BTW the PASSWORD('mypass') part allows the password to be hashed.) I have tried changing the password to not hash but this doesnt work either. I also have the mail settings turned off, so my password cannot be emailed to me. I looked through the php_login.php page and I cant seem to sort out how the login page is passing the password into MySQL so I can login.

  2. Chris_K
    Posted 9 years ago #

    update your wp-config.php file to use the new password?

  3. rcmullins
    Posted 9 years ago #

    Well, I didnt change the password to the DB. I changed the admin password to get into wordpress, but i did it using sql query through the mysql, using a hash. Maybe im not being very clear?

  4. rcmullins
    Posted 9 years ago #

    HandySolo: I figured out a way to do it, without using the phpMyAdmin thing. Using a sql command you can hash using the MD5 hashing algorithm. Its really quite easy too. Thanks to you for pointing me in the right direction. Here is the query.

    UPDATE wp_users SET user_pass = MD5('mypass') WHERE ID = 1;

    For anyone out there here is how it works.

    You log into your wordpress database within MySQL. There are several ways to do this, using the commanline or the new MySQL query analyzer. The password and user information is located in the table wp_users. Once you are 'using' the correct database you just execute the above command/query. Since all the admin stuff is located in id# 1 the only thing you will have to alter is the 'mypass' part. Just fill in your desired password, and you should be set.

    Anybody who needs more explanation on this, please feel free to email me at;
    rcmullins@centurytel.net It may take me a day to get to you, but I will try to respond the best way I know how.

    Thanks again to HandySolo for helpin meh.

Topic Closed

This topic has been closed to new replies.

About this Topic