Magento code change password user admin


Magento code change password user admin

In anyday, you unable to log in to Magento system.

magento forgot password
Don’t worry, you don’t remember but you still can reset your admin password.
You are a Magento developer and want a quick and easy way to set an admin account password by code.
You need add below code to PHP file at anywhere:


require_once('app/Mage.php'); //Path to Mage Magento
//set password following username, below demo with username: khactung

echo "Successfully Changed";

After run, you can login to Magento system by username and new password. And don’t forget you need remove this code after finished.


Thanks for watching!