I do not see any obvious signs on the front end of my store however when I enable the system.log and exception.log I'm seeing A LOT of entries.
First, from the system log, I'm seeing the following error (and corresponding code that is being referenced):
2013-06-04T22:55:31+00:00 ERR (3): Notice: Undefined variable: name in /home/XXXXXX/public_html/app/code/core/Mage/Page/Block/Html/Head.php on line 55
line 55: $this->addItem('skin_css', $name, $params);
2013-06-04T22:55:31+00:00 ERR (3): Warning: Missing argument 1 for Mage_Page_Block_Html_Head::addCss() in /home/XXXXXX/public_html/app/code/core/Mage/Page/Block/Html/Head.php on line 53
line 53: public function addCss($name, $params = "")
2013-06-04T22:55:35+00:00 ERR (3): Notice: Undefined variable: gravdept_filterClass in /home/XXXXXX/public_html/app/design/frontend/gravdept/acumen/template/catalog/layer/filter.phtml on line 38
echo '<li class="'.$gravdept_filterClass.'">
<a href="'.$_item->getUrl().'">'.$_item->getLabel().'</a>';
Then, in the exception.log, I'm seeing the following error over and over:
2013-06-04T23:01:14+00:00 ERR (3):
exception 'Mage_Core_Exception' with message 'Invalid block type: ' in /home/XXXXXXX/public_html/app/Mage.php:594
Stack trace:
#0 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(495): Mage::throwException('Invalid block t...')
#1 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(437): Mage_Core_Model_Layout->_getBlockInstance('', Array)
#2 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(472): Mage_Core_Model_Layout->createBlock('', 'checkout.cart')
#3 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(239): Mage_Core_Model_Layout->addBlock('', 'checkout.cart')
#4 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(205): Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
#5 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#6 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(344): Mage_Core_Model_Layout->generateBlocks()
#7 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(269): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#8 /home/XXXXXXX/public_html/app/code/core/Mage/Checkout/controllers/CartController.php(159): Mage_Core_Controller_Varien_Action->loadLayout()
#9 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Checkout_CartController->indexAction()
#10 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('index')
#11 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#12 /home/XXXXXXX/public_html/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#13 /home/XXXXXXX/public_html/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#14 /home/XXXXXXX/public_html/index.php(89): Mage::run('', 'store')
#15 {main}
Any ideas on how to fix these errors?
Best Answer
Answer for one of the errors, having run into it before...
line 55: $this->addItem('skin_css', $name, $params);
I'd start looking for a malformed line in your template layout local.xml, head.xml or page.xml
The
Head.php
block is being fed a configuration line with missing info.Typical addCss type CSS load statements are as follows:
<action method="addCss"><stylesheet>css/widgets.css</stylesheet></action>
addItem statements have the ability to use parameters for conditional loading of either JavaScript or CSS.
Typical addItem type CSS load statements in layout xml files look like the following:
<action method="addItem"><type>skin_css</type><name>css/funky.css</name><params/><if>lt IE 8</if></action>
You need to tell it:
Magento then goes to your current active template skin folder, looks for the css folder and loads the file. Apparently the file name is bunged up in one of the lines which causes Head.php to choke.
I'd run grep from the command line and look for all addItem lines in in the layout folder in my currently active template (paying close attention to the CSS versions and then back up and look for layouts added by third party modules.