【问题标题】:Magento My Account new pageMagento 我的帐户新页面
【发布时间】:2015-12-18 09:03:36
【问题描述】:

我想将新页面添加到我的帐户部分。我需要在这个页面中放置一个带有一些自定义逻辑的 iframe。

我已尝试在以下部分添加链接。

<reference name="left">
        <block type="customer/account_navigation" name="customer_account_navigation" before="-" template="customer/account/navigation.phtml">
            <action method="addLink" translate="label" module="customer"><name>account</name><path>customer/account/</path><label>Account Dashboard</label></action>
            <action method="addLink" translate="label" module="customer"><name>account_edit</name><path>customer/account/edit/</path><label>Account Information</label></action>
            <action method="addLink" translate="label" module="customer"><name>address_book</name><path>customer/address/</path><label>Address Book</label></action>
        </block>

        <block type="catalog/product_compare_sidebar" name="catalog.compare.sidebar" template="catalog/product/compare/sidebar.phtml"/>
        <remove name="tags_popular"/>

    </reference>

但它会产生 404 错误。

【问题讨论】:

    标签: magento custom-pages


    【解决方案1】:
    Use this 
     <customer_account>        
            <reference name="customer_account_navigation">           
            <action method="addLink" translate="label" module="modulename">
                <name>Tab Name</name>
                <path>path/index/index</path>
                <label>Tab Info</label>
            </action>      
        </reference>    
    </customer_account>  
        <modulename_index_index>
        <update handle="customer_account"/>
        <reference name="my.account.wrapper">    
     <block type="blockname/blockname" name="blockname" template="file.phtml" />
            </reference>    
        </modulename_index_index>
    

    【讨论】:

    • 你好 Sushil,谢谢你的回答,但你能解释一下我需要在哪个文件中添加这个吗?
    • customer.xml您当前的主题,如果对您有帮助,请选择它作为您的答案
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多