0
當添加在Magento一個子類別,我得到這個錯誤:的Magento:調用一個成員函數計數()非對象上
Fatal error: Call to a member function count() on a non-object in C:\wamp\www\cariocawear_new\app\code\local\Mage\Catalog\Block\Navigation.php on line 324
這是在其中線324是函數:
public function drawImgItem($category, $level = 0, $last = false)
{
$html = '';
$categoryName = '';
if (!$category->getIsActive()) {
return $html;
}
$children = $category->getChildren();
$hasChildren = $children && $children->count(); <-- This is line 324 which cause error
$html.= '<li';
if ($hasChildren) {
$html.= ' onmouseover="toggleMenu(this,1)" onmouseout="toggleMenu(this,0)"';
}
/* snipped by editor for being superfluous */
}
現在得到這個錯誤出現了一個錯誤處理您的請求SQLSTATE [42S22]:列未發現:在1054未知列'CATEGORY_ID「where子句」 – Muzammil 2011-02-02 14:10:00