Testing With The Dynamic Product Test Page

After you create a default dynamic product and a campaign, we ask you to test your dynamic product. You test it with the Dynamic Product Test Page.

When customers click a product’s TrialPay payment option link, they are clicking an HTML form. The form sends us a POST request containing the product’s information. We then replace your Landing Page’s Default Product information with the new information contained in the request.

The Dynamic Product Test Page simulates the entire process. It has two steps:

  • Step 1 gathers information about a product and formats it according to our requirements.
  • Step 2 adds the formatted product information to an HTML Form, and then displays both the formatted product information as well as the completed HTML form button.

If you click the completed HTML form button, it sends us the product information. We then replace your Landing Page’s default product information with the new product information, and display the updated Landing Page to you.

Step 1 (of 2): Define Dynamic Data

Product Settings

This information will be formatted and added to your HTML form as an INPUT value. Any information you supply will be included in the form’s POST request, and used to replace your product Landing Page’s corresponding default values.

Product Setting Required Type Char. Limit Description
POST Schema Version X Integer NA Schema versions tell us how the POST will be structured. Set this to 1 unless told otherwise
Product Internal Name String 255 Your product’s Internal Name.
Product Banner String 255 The URL for a banner image that spans your product’s Landing Page.
Product Offering Image String 255 The URL for a 125×125 pixel image that represents your product, or set of products.
Max Report Time Integer NA Don’t display advertiser offers to this customer that take more than this number of days to complete.
MAP X Float NA The minimum amount you are willing to accept from an advertiser for this product.
Alternate Payment URL String 255 The URL you want to show customers when there are no advertiser offers available.
Return URL String 255 This is the URL you want to show customers when they complete an Advertiser Offer.
Dynamic Merchant ID Integer NA This is an ID you assign a specific merchant. Please contact Merchant Support if you need to identify specific third-party merchants.

TABLE 1 Product Settings

Product Details

This information will be formatted and added to your HTML form as an INPUT value. Any information you supply will be included in the form’s POST request, and used to replace your product Landing Page’s corresponding default values.

You can provide information about additional products. Note, however, that each new product’s information is limited to the five Product Details listed below. Also, you cannot provide individual MAPs for each product. The MAP listed in the Product Settings section applies to the total value of your combined products. Please refer to the Multiple Productssection later in this document, for details.

Product Setting Required Type Char. Limit Description
Product External Name X String NA The name that will appear on your product’s Landing Page. It should clearly identify your product or offer.
Product Description X String 255 Describes your product or offer, and should highlight its features.
Product Price X Float NA The product or offer’s retail price you show to customers.
Product Currency X String 5 The currency symbol you want to accompany your retail price.
Product ID Integer NA The product’s ID or SKU number.

TABLE 2 Product Details

Message Encoding

We format the information you enter in the Product Settings and Product Details sections, and then add it to the HTML form as an INPUT attribute’s value. You can choose one of two formatting methods: standard URL formatting (less secure) or URL/AES formatting (more secure).

Encoding Description
URL Standard URL formatting, with Settings and Details (which are parameters) separated by & and +characters.
URL/AES Standard URL formatting, but then encrypts the URL.

TABLE 3 Message Encoding

You can see how the formatted product information looks in Step 2 of the Dynamic Product Test Page. For more information about URL and URL/AES formatting, please refer to the Appendix of our Online Help.

GET Parameters

The test can append information to your Campaign’s URL, the same way an HTTP GET request appends them: as parameters. When we receive the URL contained in the POST request, we can read (parse) the parameter values and use them.

Parameter Required Type Char. Limit Description
First Name String 255 Your customer’s first name.
Last Name String 255 Your customer’s last name.
Email String 255 Your customer’s e-mail address.
SID X String 50 The unique ID you assign the product or transaction. We can return this value in script notifications.

TABLE 4 GET Parameters

We can display the first name, last name, and e-mail address values in the product Landing Page’s sign-up form.

The SID identifies the product, but can also be used to identify a set of products, or identify a shopping cart. Please refer to the Multiple Products section for more information about identifying multiple products.

Step 2 (of 2) – Create HTML Form

HTML Form

This page takes all of the product information you provided in Step 1, and assigns it to three INPUT attributes. It then formats and displays the information as a value for each of the INPUT attributes.

Input Name Description
enc This tells us the method used to encode the product information.
message This is your product information, encoded as a standard URL, or a URL encrypted by AES.
hmac This is your encoded product information’s HMAC MD5 authentication code. It guarantees the information’s authenticity.

TABLE 5 HTML Form

The test inserts the values for each of the INPUTs above into HTML Form code similar to the sample code below:

<form action=”[your campaign URL]” method=”post” style=”margin-left: 15px;”>
<input type=”hidden” name=”enc” value=”[enc value]” />
<input type=”hidden” name=”message” value=”[message value]” />
<input type=”hidden” name=”hmac” value=”[hmac value]” />
<button type=”submit”>Go To TrialPay</button>
</form>
</code>

Here is the complete sample code, with the three INPUT values and sample attributes:

<form action=”http://www.trialpay.com/dc/?c=21dcb92&tph=0f7c848ae33de5e2&toi=Y4mVms&sid=12345″ method=”post” style=”margin-left: 15px;”>
<input type=”hidden” name=”enc” value=”url” />
<input type=”hidden” name=”message” value=”version=1&map=100&product1_name=Blue+Widget&product1_description=It%27s+just+like+a+red+widget%21&product1_price=120&product1_currency=USD” />
<input type=”hidden” name=”hmac” value=”3ba115729e07630057b12618a145b93d” />
<button type=”submit”>Go To TrialPay</button>
</form>

The Go To TrialPay button displayed on the test page is an example of what the HTML form code looks like to a customer. The sample button contains all of the information you supplied in Step 1. If you click the button, it will display your Dynamic Product’s Landing Page, with all of the new information in place.