cancel
Showing results for 
Search instead for 
Did you mean: 

Fatal error: Uncaught Error: Function name must be a string in

Fatal error: Uncaught Error: Function name must be a string in

Hello i have following error, can someone help me with what to do? many thanks for your help


Fatal error: Uncaught Error: Function name must be a string in /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Core/Model/Layout.php:529 Stack trace: #0 /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Core/Controller/Varien/Action.php(391): Mage_Core_Model_Layout->getOutput() #1 /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Cms/Helper/Page.php(132): Mage_Core_Controller_Varien_Action->renderLayout() #2 /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), 'shopper_home_2c...') #3 /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), 'shopper_home_2c...') #4 /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Core/Controller/Varien/Action.php(420): Mage_Cms_IndexContro in /home/httpd/vhosts/domain/shop.domain/app/code/core/Mage/Core/Model/Layout.php on line 529

3 REPLIES 3

Re: Fatal error: Uncaught Error: Function name must be a string in

Hi @mustermann7 

 

This might be your PHP related issue but there is a fix go to this file

 

 

app\code\core\Mage\Core\Model\Layout.php:555 

replace this with

 

 

$out .= $this->getBlock($callback[0])->$callback[1]();

with this 

 

 

$out .= $this->getBlock($callback[0])->{$callback[1]}();

for more reference go through Fatal error: Uncaught Error: Function name must be a string

this might help you.

 

this is the fix which i won't recommend as we are changing in core files. i would recommend  you to check your php version.

 

if above answer was helpful then please Accept as Solution & give Kudos
Shubham Khandelwal 

 

Re: Fatal error: Uncaught Error: Function name must be a string in

Thank you very much! It helps me to fix the error/problem.

Re: Fatal error: Uncaught Error: Function name must be a string in

Hi @sven_pruefer 

 

Glad to know it fixed your issue.kudos to coding.

 

if above answer was helpful then please Accept as Solution & give Kudos
Shubham Khandelwal