如何从 magento 的主页中删除搜索框。
我在 CMS > Pages > home
页面中搜索,没有找到与搜索框相关的代码。
我可以使用此链接删除每个目录 View 和产品 View 页面中的搜索框
“http://www.magentocommerce.com/boards/viewthread/38420/”。
如何从主页中删除。
提前致谢。
最佳答案
转到 app/design/frontend/YOUR_THEME_NAME/default/template/page/html/header.php 行号:- 38 请使用此代码。
<?php echo $this->getChildHtml('topSearch') ?>
到
<?php if(Mage::getSingleton('cms/page')->getIdentifier() != 'home' && Mage::app()->getFrontController()->getRequest()->getRouteName() == 'cms') : ?>
<?php echo $this->getChildHtml('topSearch') ?>
<?php endif;?>
关于php - 从 Magento 主页移除搜索框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23332483/