我有一家 magento 多店。当我在商店 A 中搜索产品时,它会返回商店 B 的产品。在商店 A 中进行搜索时,如何限制搜索仅返回商店 A 的产品?
问问题
2383 次
2 回答
0
You can also setup different folders for your stores to seperate them more:
e.g.:
de-de/
de-en/
ch-de/
ch-fr/
put in each folder the "errors" folder and the index.php. Edit the index.php and add at the end:
Mage::run('chde','store');
sure, depending on your whole store configuration.
In each template use either the <base href>
or prepend any link with Mage::getBaseUrl()
于 2012-07-09T20:43:49.047 回答
0
如果您询问 php 代码实现,请查看下面的示例
//create product collection
$collection = Mage::getResourceModel('catalog/product_collection');
//.... //add necessary filters, conditionas, etc
$collection->addStoreFilter(); // add current store filter to products collection
于 2012-07-09T06:55:58.073 回答