Magento分层导航块.移到中心 [英] Magento Layered Navigation block. Move to center

查看:100
本文介绍了Magento分层导航块.移到中心的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

category.xml中,我正在以下位置更改引用名称:

In category.xml I'm changing the reference name in:

    <reference name="left">
        <block type="catalog/layer_view" name="catalog.leftnav" before="-" template="catalog/layer/view.phtml"/>
    </reference>

我假设

content会将分层的nav放置在中心.但是,它仍然停留在左侧.实际上,即使我将left更改为right,它仍然不会从左侧边栏中移动.

To content which I assumed would place the layered nav into the center. However, it still stays on the left. In fact, even I changed left to right, and it still doesn't move from the left sidebar.

我在做什么错了?

推荐答案

我设法通过注释掉或删除catelog.xml中的以下调用来解决此问题(针对遇到此问题的其他人):

I managed to fix this (for anyone else who encounters this problem) by commenting out or deleting the below call in catelog.xml:

<reference name="left">
    <block type="catalog/layer_view" name="catalog.leftnav" before="-" template="catalog/layer/view.phtml"/>
</reference>

然后在下面的name="product_list"块中添加此行.

Then adding this line within the name="product_list" block just below.

<block type="catalog/layer_view" name="filter" template="catalog/layer/view.phtml"/>

然后在list.phtml中将其回显为:<?php echo $this->getChildHtml('filter');?>

Then within list.phtml echo it like: <?php echo $this->getChildHtml('filter');?>

这篇关于Magento分层导航块.移到中心的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆