Two Recurring Products (and one lifetime product) On Signup: ERROR

Discussion in 'Payments processing' started by dan_kelly, Sep 29, 2009.

  1. dan_kelly

    dan_kelly New Member

    Joined:
    Aug 29, 2006
    Messages:
    91
    I have figured out through much trial and error that the only way to have ONE recurring product and one lifetime product on the signup page is to have the recurring product ABOVE the lifetime product in the HTML *AND* make the product_id INPUT variable an array by adding "[]" to the NAME.

    Code:
    When you View Source you see the recurring product before the lifetime product. 
    
    <input type="hidden" id="product2" name="product_id[]" value="2" />
    <input type="hidden" id="product16" name="product_id[]" value="16" />
    
    product2 is recurring.
    product16 is lifetime.
    ...otherwise, there will be an expiration date on the lifetime product.


    -----

    Now, I am trying to add TWO recurring products on the signup page; and the user should be able to select BOTH... along with the lifetime product.

    So far, I have found that BOTH recurring products must be above the lifetime product in order for the lifetime product to have no expiration date.

    BUT...

    The expiration dates for the two recurring products are messed up.

    Here's what happens...

    product2 is recurring - 45 day trial + monthly billing.
    product8 is recurring - 7 day trial + 90 day billing. (for this example)
    product16 is lifetime.

    AFTER THE PURCHASE IS COMPLETE, I go to aMember Payments; and here's the result.

    product2 expires in 7 days.
    product8 expires in 90 days.
    product16 is lifetime. Wohoo!

    Notice that aMember is pulling the trial days for both recurring products from the trial and recur days for the second product in the array. :confused:

    Any thoughts/code on how to fix this?

    dK

    PS. Another question is, will the recur days for both products follow the schedule set forth in the product setup for FUTURE payments?

Share This Page