0
Warning: Missing argument 1 for Mage_Core_Block_Template::setTemplate()  in /var/www/magento/app/code/core/Mage/Core/Block/Template.php on line 111

0 /var/www/magento/app/code/core/Mage/Core/Block/Template.php(111): mageCoreErrorHandler(2, 'Missing argumen...', '/var/www/magent...', 111, Array)
1 [internal function]: Mage_Core_Block_Template->setTemplate()
2 /var/www/magento/app/code/core/Mage/Core/Model/Layout.php(348): call_user_func_array(Array, Array)
3 /var/www/magento/app/code/core/Mage/Core/Model/Layout.php(214): Mage_Core_Model_Layout->_generateAction(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
4 /var/www/magento/app/code/core/Mage/Core/Model/Layout.php(206): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
5 /var/www/magento/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
6 /var/www/magento/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
7 /var/www/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(344): Mage_Core_Model_Layout->generateBlocks()
8 /var/www/magento/app/code/core/Mage/Cms/Helper/Page.php(113): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
9 /var/www/magento/app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), 'home')
10 /var/www/magento/app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), 'home')
11 /var/www/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Cms_IndexController->indexAction()
12 /var/www/magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('index')
13 /var/www/magento/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
14 /var/www/magento/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
15 /var/www/magento/app/Mage.php(684): Mage_Core_Model_App->run(Array)
16 /var/www/magento/index.php(83): Mage::run('', 'store')
17 {main}

I got this error after updated my magento. I have no idea why its happened. Need some help here.

0

When setting a template, you'll need to set the relative template path in the setTemplate() method. This error tells you that you didn't set a value there, so just set the correct template path and you're good.

| improve this answer | |
  • How do we do that? – fiq Feb 5 '16 at 7:05
  • That depends, you can either set it with PHP with $variable->setTemplate('path/to/my/template.phtml'); or with XML with <block type="module/block" name="my.block" template="path/to/my/template" />. You'll need to find out which file currently breaks and fix that file. Which file that is, is hard to tell from the code you've added. – Arjen Miedema Feb 6 '16 at 5:59

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.