我已经安装了Magento CE 1.9版本,但我在主页上调用目录后出现错误。这个问题与list. php .
有关。我已经搜索了相关的解决方案来解决这个致命的错误,并得到了一个合适的答案。
我已经看了下面的链接:
Magento致命错误:在非对象上调用成员函数getSortedChildren()
按照上面链接给出的解决方案,我已经替换了所有的代码,但是这样做之后,错误已经消失,但是主页的设计扭曲了。有人能在这方面帮助我吗?
我在主页上写了以下代码:
{{block type="catalog/product_list" name="home.catalog.product.list" alias="products_homepage" category_id="3" template="catalog/product/list.phtml"}}
我试着解决这个问题,最后我用一些CSS固定。
编辑此文件app/design/frontend/yourpackagename/yourthemename/template/catalog/product/list。添加73行和135行代码getChild("name.after '))): ?>
just before:
$_nameAfterChildren = $this->getChild('name.after')->getSortedChildren();
and add this code at 82 and 144 line
<?php endif; ?>
right after
<?php endforeach; ?>