前段时间将magento升级到了1.5,经测试,有很多功能都不能使用,比如快速搜索功能。

问题:在搜索框内不论输入任何字符,都只返回一种产品!

解决方法:

编辑app/code/core/Mage/CatalogSearch/Block/Result.php

删除149-150行前注释

$this->getListBlock()
->setCollection($this->_getProductCollection());
修改172行
$this->_productCollection = $this->getListBlock()->getLoadedProductCollection();

$this->_productCollection = Mage::getSingleton('catalogsearch/layer')->getProductCollection();
进入后台System > Index Management) and 选择all the Indexes > Pick action is “Reindex data” > 点击“Submit”. 然后删除缓存即可!
吐舌头

转载请注明出处!

本文链接地址http://blog.csdn.net/shangxiaoxue/article/details/6592386

Logo

Agent 垂直技术社区,欢迎活跃、内容共建。

更多推荐