Announcement

Collapse
No announcement yet.

Add Tokens to Abandoned Basket Email

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Add Tokens to Abandoned Basket Email

    GOAL:
    I am currently expanding the default Abandoned Basket feature of MIVA and would like the EMAIL_ABANDONED_BASKET page to be sent to any customer who logs in and leaves a basket unattended as well as a guest that does the same (when capable).

    PROCESS:
    I have noticed that the only way this email sends to either a guest or logged in customer is after an item is in the basket, the customer goes to checkout and proceeds past the Billing / Shipping portion of the checkout process. After Bill/Ship, their session is updated with a “g.basket:bill_email” value and a “g.basket:bill_fname” which appears in the Miva backend under Utility Settings > Review Baskets.

    ISSUE:
    If a logged in customer drops a basket without going to the checkout screen and, essentially, defining their Bill/Ship address (even though that data is stored elsewhere for the customer but is not used in this instance) no Abandoned Basket email is sent. So how can I ensure Miva uses the available email for the customer if they simply log in > add to cart > then drop it?
    The Customer Password Email (g.customer:pw_email) populates in the Review Baskets batch list but using this token for the Send To email still does not work.

    This is an example snippet to capture a usable email for Send To (just does not work):
    Code:
    <mvt:comment>Define the Send To Email Address via g.basket:sendto_email</mvt:comment>
    <mvt:if expr="NOT ISNULL g.basket:bill_email">
        <mvt:assign name="g.basket:sendto_email" value=" g.basket:bill_email " />
    <mvt:else>
        <mvt:assign name="g.basket:sendto_email" value=" g.customer:pw_email " />
    </mvt:if>
    <strong>Hello &mvt:global:customer:bill_fname;, (&mvt:global:basket:sendto_email;)</strong>
    Thank You.
    -Benjamin
    Benjamin Smith - Developer
    www.midwestgunworks.com
Working...
X