I'm new to Magento 2.
Fatal error: Class 'Mage' not found in \vendor\magento\module-theme\view\base\templates\root.phtml on line 23
Can anybody tell me how to solve this?
I'm new to Magento 2.
Fatal error: Class 'Mage' not found in \vendor\magento\module-theme\view\base\templates\root.phtml on line 23
Can anybody tell me how to solve this?
It looks like the theme you installed is not compatible with Magento 2.
Aparently it has a Mage::...() call in one of the files.
Mage is deprecated in Magento2.
Magento2, not using factory Patten types like Mage::getModel ,Mage::getsingleton() etc
It now uses the class nameSpace concept
To learn more about how to use ObjectManager in Magento 2, checkout these links:
in magento 2 call the model any where
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$model = $objectManager->create('\Namespace\Modulename\Model\Modulename');