Setting up your site can be as easy as adding your products to our database and then placing the HTML that we automatically generate for you on your site.
Below, we'll show you how to modify the automatically generated HTML to provide some additional functionality without the need for a third-party shopping cart.
Try it out! Make a demo purchase to see how easy it is. Provide a valid email address with your order, and you'll see an example of the email you and the buyer will receive with every successful purchase.
The Acme Online Books account is always in demo mode, so you won't be charged for any purchases.
This is a simple product purchase. Clicking the purchase button will add the product to your shopping cart. This code is very similar to the code generated automatically by your 2CO account when you add products to our database.
There's no special code required for recurring products. Simply, choose your recurring terms when editing your products in the 2CO administration panel.
Price: $29.99
<form action="https://www.2checkout.com/checkout/purchase" method="post">
<p>
<input type="hidden" name="quantity" value="1" />
<input type="hidden" name="product_id" value="1" />
<input type="hidden" name="sid" value="1303908" />
<input type="submit" class="submit" name="purchase" value="Buy from 2CO" />
</p>
</form>
This purchase form will allow the customer to set the quantity, while they are still on your site.
Price: $19.99
<form action="https://www.2checkout.com/checkout/purchase" method="post">
<p>
<label for="quantity_input">Quantity:</label>
<input type="text" size="3" value="1" name="quantity" id="quantity_input" />
<input type="hidden" name="product_id" value="6" />
<input type="hidden" name="sid" value="1303908" />
<input type="submit" class="submit" name="purchase" value="Buy from 2CO" />
</p>
</form>
This purchase form will allow the customer to set the quantity with a dropdown menu, while they are still on your site.
Price: $39.99
<form action="https://www.2checkout.com/checkout/purchase" method="post">
<p>
<label for="selectable_quantity">Quantity:</label>
<select name="quantity" size="1" id="selectable_quantity">
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
</select>
<input type="hidden" name="sid" value="1303908" />
<input type="hidden" name="product_id" value="7" />
<input type="submit" class="submit" name="purchase" value="Buy from 2CO" />
</p>
</form>
Options like "Paperback", "Hard Cover", "Download", or anything else you can imagine, may be created as individual products in your 2CO account and then provided as product options via a dropdown menu on your site.
You may instead choose to create product options in your 2CO account. These will then be available on the 2CO purchase routine pages for your products.
<form action="https://www.2checkout.com/checkout/purchase" method="post">
<p>
<label for="book_type">Book type:</label>
<select name="product_id" size="1" id="book_type">
<option value="1">Hard Cover - $29.99</option>
<option value="3">Paperback - $19.99</option>
<option value="4">Download - $9.99</option>
</select>
<input type="hidden" name="quantity" value="1"/>
<input type="hidden" name="sid" value="1303908"/>
<input type="submit" class="submit" name="purchase" value="Buy from 2CO" />
</p>
</form>