Fatal error: Uncaught ArgumentCountError: Too few arguments to function Mage_Page_Block_Html_Head::addCss(), 0 passed in /home/app/code/core/Mage/Core/Model/Layout.php on line 348 and at least 1 expected in /home/app/code/core/Mage/Page/Block/Html/Head.php:53 Stack trace: #0 /home/public_html/app/code/core/Mage/Core/Model/Layout.php(348): Mage_Page_Block_Html_Head->addCss() #1 /home/public_html/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)) #2 /home/public_html/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#3 /home//public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(344): Mage_Core_Model_Layout->generateBlocks() #4 /home//public_html/app/code/core/Mage/Catalog/Helper/Produc in /home/public_html/app/code/core/Mage/Page/Block/Html/Head.php on line 53
  • check files this addCss function getting blank value.
    – kunj
    Commented May 28, 2018 at 18:06
  • Post your css adding code here Commented May 28, 2018 at 18:15

2 Answers 2


You are appealing to a nonexistent element.


I got same error when i was setup a magento 1.9 website locally. Please go to /app/code/core/Mage/Page/Block/Html/Head.php on line 53 and change the code as below:

-public function addCss($name, $params = "")

+public function addCss($name="", $params = "")

It works for me. Cheers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.