If you are using the default success URL option, or the “custom” setting if your product has an upsell flow attached to it, ThriveCart will return information about the order to that page via query string variables.
In addition to this, you can also pass through your own custom variables to the success page of your order. You do this by attaching variables to the ‘passthrough’ query string parameter when customers start your checkout process.
In this example, your checkout URL is http://webactix.thrivecart.com/example-product/ (you would replace this with the real URL to your product).
Step 1: Specifying the variables
You can simply create a standard link containing the variables you need:
Alternatively, you can use a form to send variables. This is useful if you want to allow your users to enter information into an input. For example, you could ask them for their favourite colour, and then use that information on your success page! In the example below, we will use a hidden input, but this could easily be any standard HTML input.
<form action="http://webactix.thrivecart.com/example-product/" method="get"> <input type="hidden" name="passthrough[example_key]" value="example_value" /> <input type="submit" value="Go to my checkout" /> </form>
Step 2: Checkout process
Now your customer will go through the cart process as normal. Once they have entered their details and card info, they will be taken to our confirmation page and presented with the links to access their new purchase (or automatically redirected to your custom success page if you have set this up).
Step 3: Your success page
On your success page, you will receive your key and value pairings as query-string variables. In the above examples, you could access them as follows using PHP:
<?php $example_key = $_GET['example_key']; // In the example, this will be set to 'example_value' ?>
Note, any custom pass through information is not included in the hash used to validate the order. Also, this functionality is not supported by popup templates or embeddable templates.
As always if you have any questions please don’t hesitate to get in touch with us via email@example.com