Can You Pass Variables To Thank you Page After Payment?

Discussion in 'Integration' started by zimsolve, Aug 25, 2008.

  1. zimsolve

    zimsolve New Member

    Joined:
    Apr 5, 2007
    Messages:
    21
    I'm trying to figure out how to pass the "plan" variables or product id variables to the thank you page after a purchase through 1shoppingcart.

    Basically, we have 3 plans... silver, gold, platinum.

    After the purchase, the buyer is asked to sign up on the "buyers" list which would pre-populate the ad-tracking hidden filed with the product id to distinguish which plan that user purchased. We're doing this since each person has different autoresponder messages and offers.

    Is there a way to pass this info onto the product url page and insert onto the webpage?

    Thanks :)
  2. davidm1

    davidm1 aMember User & Partner

    Joined:
    May 16, 2006
    Messages:
    4,437
    I think you can just use the amember variables on the thanks.html page.
    {foreach from=$products item=p}
    {if $p.product_id eq "1"}
    your hidden field
    {/if}
    {/foreach}

    David
  3. zimsolve

    zimsolve New Member

    Joined:
    Apr 5, 2007
    Messages:
    21
    I just tried it on the thankyou.html page, but it didn't appear. I'm not sure how to place the "hidden field" you have in between the code.

    Here is what the file looks like:

    Code:
    {assign var="title" value=$smarty.const._TPL_THX_TITLE}
    {include file="header.html"}
    
    <div id="wrap">
        <div class="clearer"></div>
    <div id="signupcontent">
      <p><strong>#_TPL_THX_ENJOY|<a href="{$config.root_url}/login.php">|</a>#</strong>
          <br />
        
          <!-- display payment receipt -->
        {if $payment.amount > "0.0"}
        
        #_TPL_THX_PAYPROC# <br />
        #_TPL_THX_ORDERREF|{$payment.payment_id}|{$payment.receipt_id}#<br />
        #_TPL_THX_DATETIME|{$payment.tm_completed|date_format:$config.time_format}#</p>
      <p>{foreach from=$products item=p}<br>
      {if $p.product_id eq "1"} <br>
      <input type="hidden" name="hiddenField" id="hiddenField">
    <br>
    {/if}<br>
    {/foreach}
        
          <br />
          <br />
          {include file="receipt.inc.html"} <br />
          <br />
        {/if}{* END Of receipt display *} </p>
      </div>
    </div>
    {include file="footer.html"}
    
  4. davidm1

    davidm1 aMember User & Partner

    Joined:
    May 16, 2006
    Messages:
    4,437
    You mean thanks.html?
    Is the payment amount greater than 0?
    Are you getting the other parts of the receipt?

    David

Share This Page