2010-08-20 32 views
1

我試圖將'最近查看產品'區塊移動到右邊欄'比較產品'區塊下方。我已經通過以下包含在local.xml中來實現此目的,但是,產品查看塊現在出現了兩次,原始文件仍位於頂部。我該如何編碼xml才能將頂部發送到底部,而不是像我所做的那樣進行復制?如何在Magento中更改產品比較和查看區域的順序?

<reference name="right"> 
    <!-- Mage_Reports --> 
    <block type="reports/product_compared" name="right.reports.product.compared" template="reports/product_compared.phtml" after="-"> 
     <action method="setBlockId"><block_id>product_compared</block_id></action> 
    </block> 
    <block type="reports/product_viewed" name="right.reports.product.viewed" template="reports/product_viewed.phtml" after="-"> 
     <action method="setBlockId"><block_id>product_viewed</block_id></action> 
    </block> 
</reference> 

回答

0

product_viewed塊被插入app/design/frontend/yourinterface/yourtheme/layout/catalog.xmlapp/design/frontend/yourinterface/yourtheme/layout/reports.xml。如果刪除這些文件中的相應標籤,該塊應只出現一次。 如果這些文件不包含在您的主題中,只需將它們從app/design/frontend/base/default/layout/複製到您的主題中,然後進行編輯。

快樂編碼:-)