wonderphp

Some wonder in PHP


Reset the password in drupal 7


If you forgot the password of your drupal admin then dont worry,

just follow some steps given here:

add following code in root index.php file on the top

define(‘DRUPAL_ROOT’, getcwd());
require_once DRUPAL_ROOT . ‘/includes/bootstrap.inc’;
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
require_once ‘includes/password.inc’;
echo user_hash_password(‘your-new-password’); die();

now copy this password and update in your database.

Have a fun

 



Leave a comment

About Me

A seasoned web developer with over 14 years of experience, has honed a craft across a variety of frameworks and platforms.

Newsletter