Skip to main content
deleted 35 characters in body
Source Link

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But not sure how to generate in magento 2.

I have search complete /vendor/magnetomagento/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But not sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But not sure how to generate in magento 2.

I have search complete /vendor/magento/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);
edited body
Source Link
Rahul
  • 199
  • 5
  • 21

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But nownot sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But now sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But not sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

added 328 characters in body
Source Link
Rahul
  • 199
  • 5
  • 21

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But now sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But now sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Any help would be appreciated.

I want to generate password reset token in Magento 2.

In magento 1, I was generating token by using below code -

$oldtoken = $cust->getRpToken();
$newResetPasswordLinkToken = Mage::helper('customer')->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);`

But now sure how to generate in magento 2.

I have search complete /vendor/magneto/module-customer but not able to generate Token.

Edit -

Code for Magento 2 -

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$helper = $objectManager->get('\Magento\Customer\Helper\View');
$newResetPasswordLinkToken = $helper->generateResetPasswordLinkToken();
$cust->changeResetPasswordLinkToken($newResetPasswordLinkToken);

Any help would be appreciated.

Remove Magento 1 tags
Source Link
sv3n
  • 11.7k
  • 7
  • 41
  • 73
Loading
added 9 characters in body
Source Link
Rahul
  • 199
  • 5
  • 21
Loading
Source Link
Rahul
  • 199
  • 5
  • 21
Loading