Forgot password not sending email

﹥>﹥吖頭↗ 提交于 2019-12-13 02:49:58

问题


Wonder if you can help me. I have a Magento installation and when a customer selects "forgot password" the system does NOT send the reset password email.

All the other emails are working fine. I have setup the New Password template and assigned it in the admin of Magento.

I can't for the life of me figure out why only the Reset password emails are not sending and the others are.

Please help.

Thanks, Ev


回答1:


To solve the issue it is enough to delete the custom customer.xml used by your theme in app/design/frontend///layout/, so default layout shipped with base theme (in app/design/frontend/base/default/layout/customer.xml) will be used.

Or the custom customer.xml can be updated to include the following section:

<customer_account_resetpassword translate="label">
    <label>Reset a Password</label>
    <remove name="right"/>
    <remove name="left"/>

    <reference name="head">
        <action method="setTitle" translate="title" module="customer">
            <title>Reset a Password</title>
        </action>
    </reference>
    <reference name="root">
        <action method="setTemplate">
            <template>page/1column.phtml</template>
        </action>
        <action method="setHeaderTitle" translate="title" module="customer">
            <title>Reset a Password</title>
        </action>
    </reference>
    <reference name="content">
        <block type="customer/account_resetpassword" name="resetPassword" template="customer/form/resetforgottenpassword.phtml"/>
    </reference>
</customer_account_resetpassword>



回答2:


Check out the app/code/core/Mage/Customer/controllers/AccountController.php file. Look for forgotPasswordPostAction. Analyze it step by step - check if $this->getRequest()->getParams() provides you the emal addresss, check if it validates (maybe some local changes have been made to the validation code). Look at the password generation code - is the new passsword generated? Check out the Mage_Customer_Model_Customer class and the sendPasswordReminderEmail method and try to track the bug in there. Print all the values you can get there (email, names, store configs and check for exceptions and warnings - turn php error displaying!).

This should help you tracking down the problem, and gather enough data to identify it.



来源:https://stackoverflow.com/questions/8923150/forgot-password-not-sending-email

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!