• Resolved sonicarts

    (@sonicarts)


    Hi folks,
    really hoping someone can help me out here as am quite new to WordPress but reasonably familiar with other web stuff. I recently set up a WP site, installed very few plugins and created a few pages, etc. All has been fine and the WP version is up to date.

    The other day I logged out from the admin control panel as usual. Yesterday I found that I’ve been locked out of the admin panel with a page not found error. I researched this and tried changing the name of the plugins directory and yes that did allow me to at least see the login page.

    However, my logins don’t work. I’ve researched that and tried editing the database via phpMyAdmin as per instructions seen elsewhere on this site but my logins don’t work. I do get the option to reset my password but when I click the resulting link in an email I get a ‘Sorry, that key does not appear to be valid message’. I’d also seen a suggestion to edit the theme’s functions.php file to add wp_set_password(‘password’,1); where password is replaced by my actual password but no luck.

    Any thoughts on my next steps and many thanks in advance?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Did you change the password in database using md5 hash?

    Thread Starter sonicarts

    (@sonicarts)

    Yes have tried that with no luck. I can make the change but when I open the table again it has reverted back.

    I’ve also used these steps
    https://www.wpbeginner.com/wp-tutorials/how-to-add-an-admin-user-to-the-wordpress-database-via-mysql/

    to create a new admin user but get the following after attempting to login ‘You do not have sufficient permissions to access this page’

    Thread Starter sonicarts

    (@sonicarts)

    Update: I may have managed to get the adding a new admin user via MySQL to work. I’m now logged in and seeing if all works as it should. I’ll report back when certain.

    Thread Starter sonicarts

    (@sonicarts)

    Update: OK It all worked as long as I stayed logged in. I’m now back to exactly wher eI was lat week. Locked out and my logins don’t work. I again had to rename the plugins directory even to see the login screen.

    Some thoughts on this would be really appreciated as I can’t really go through having to manually edit the database every time I want to make simple changes to the site. Many thanks.

    Hey there

    Do you have any plugin installed such as limit login attempts? Or maybe your host does? what happens when you attempt to login again after being logged out? What error message do you get when you try logging in again?

    That is one theory. The other theory is that your wp-config and site and home URL are not in agreement as to what your domain is. Check both and ensure the domain is the exact same in all three places.

    Thread Starter sonicarts

    (@sonicarts)

    Many thanks for your thoughts Mike. The only plugins installed are akismet, photo-gallery, wp-edit and wwa-advanced-wp-security.

    As for the domain suggestion, nothing is defined in the wp-config file. I can see:
    /** Absolute path to the WordPress directory. */
    if ( !defined(‘ABSPATH’) )
    define(‘ABSPATH’, dirname(__FILE__) . ‘/’);

    The siteurl in the options table is correct though.

    I would say try deactivating the security plugin while you are working in the dashboard to see if you get logged out again. Security plugins have a way of doing some weird things like this.

    Thread Starter sonicarts

    (@sonicarts)

    Now that actually worked! And tried on another browser and no problems.

    Brilliant stuff. Sincerest thanks Mike. Really appreciated.

    Nice, glad to hear it. Have a great Labor day ??

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Locked out from logging in’ is closed to new replies.