0

I have to get Email to Friend URL using Product ID Using Object Manager.

Can anyone any idea of it?

0

Using Below Code you get to Email to Friend URL using Product ID.

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$productObj = $objectManager->get('Magento\Catalog\Model\Product')->load($productId);
$emailHelper = $objectManager->create('Magento\Catalog\Helper\Product');
$emailUrl = $emailHelper->getEmailToFriendUrl($productObj);

Hope it will helps to you

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.