Magento • Fatal error: Call to a member function xpath() on a non-object in /app/code/core/Mage/Core/Model/Layout.php on line 154

Article ID #1078
Revision: 1.3
Last update: 2011-10-16

 

Symptoms

After editing / uploading a layout (an XML file) the following error message is logged:

PHP Fatal error: Call to a member function xpath() on a non-object in /app/code/core/Mage/Core/Model/Layout.php on line 154

 

Cause

The reason of the error message is that some XML path in the changed/uploaded XML file is invalid.

 

Solution

To solve the error you need to correct the XML content you recently modified or rollback the changes in layout (app/design/frontend/*/*/layout/*.xml) files.

Often, copy-pasted content (from forums/boards/blogs) contains non-ASCII characters instead of quotes/dashes, please ensure that all quotes in the pasted XML content are correct, or simply replace them.

 

Did this article help you solve your issue?


Average rating: 3.58 (12 votes)

completely useless 1 2 3 4 5 most valuable

Tags: