Hello
I have a new question (a little one this time) as you probably know i'm trying to adapt a module from prestashop to magento so i'm searching the equivalent of :
$this->context->link->getAdminLink(---------);
for Magento 2:
help pls
Solved! Go to Solution.
You can get homepage url of admin,
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); echo $objectManager->get('Magento\Backend\Helper\Data')->getHomePageUrl();
You can get other page url using,
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); echo $objectManager->get('Magento\Backend\Model\UrlInterface')->getUrl('catalog/product/index');
You can get homepage url of admin,
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); echo $objectManager->get('Magento\Backend\Helper\Data')->getHomePageUrl();
You can get other page url using,
$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); echo $objectManager->get('Magento\Backend\Model\UrlInterface')->getUrl('catalog/product/index');
thank you very much