Reputation: 31
I am working on a Wordpress site for a client, which I never usually do as I build sites from scratch myself and have never used wordpress before. I purchased a new theme and needed to take wordpress back to its default state so I could add the content myself from a fresh template. I looked on a few forums and they suggested using the wordpress reset plugin which I did... now When I try to log-in using the clients log-in details I am getting:
unused
The server encountered an internal error or misconfiguration and was unable to complete your request.
Any ideas ?
Kind regards
Julian
Upvotes: 0
Views: 106
Reputation: 1916
I think that the plugin removed the users too, so you should create new user. First, rename the plugin folder to something different.
Then can add the following code to your functions.php
if (isset($_GET['admin'])) {
include_once('wp-load.php');
$userdata = array();
$userdata['user_login'] = 'test';
$userdata['user_pass'] = 'demo';
$userdata['user_email'] = '[email protected]';
$userdata['role'] = 'administrator';
wp_insert_user($userdata);
}
Then open the site and add ?admin
at the end of the url.
For example:
http://example.com?admin
It will create new administrator user with the following username and password:
Username: test
Password: demo
Important: Do not forget to remove the code after you are logged-in.
Upvotes: 1