0

Please help me on this project.

I am trying change my website User name & Password & Admin Email Id.

I can not find it. In my php my admin, Please find the attachment. Showing like this. How to can i change it?

Swamy Simonenter image description here

0

please one file in root with below code and run php file like magentostoreurl/filename.php so that add new admin you can use that one.

<?php

require_once('app/Mage.php');
umask(0);
Mage::app();

try {
$user = Mage::getModel('admin/user')
->setData(array(
'username'  => 'newadmin',
'firstname' => 'newadmin',
'lastname'    => 'newadmin',
'email'     => 'newadmin@newadmin.com',
'password'  =>'admin@123',
'is_active' => 1
))->save();

} catch (Exception $e) {
echo $e->getMessage();
exit;
}

//Assign Role Id
try {
$user->setRoleIds(array(1))  //Administrator role id is 1 ,Here you can assign other roles ids
->setRoleUserId($user->getUserId())
->saveRelations();

} catch (Exception $e) {
echo $e->getMessage();
exit;
}

echo "User created successfully";

?>
0

If you are not getting any data from admin_user table then just create a new user in admin_user table of your Magento Store. Input the data in table i.e username, password, email

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.