How to Use a Text Link to Accommodate the Purchase of a Product

Version française (traduction en cours)

 

English Version

WP eStore has a feature that lets you use a "Text Link" to facilitate the purchase of your eStore product(s). This can be very handy when you want to use a "Call to Action" buy link on your landing page.

It can also come in handy when you need to place a link on an external site (example, your facebook page) and let the user click on the link to purchase the product via your site.

 

Requirement

You will need to check with support to make sure that the Extra eStore Shortcodes AddOn is installed and activated on your site. It should, but check it out with support.

 

How To Use a Link to Sell an eStore product

 

Lets say you have the following scenario:

1) WP eStore plugin and the Extra shortcodes addon are installed on the following domain:

http://www.example.com/

2) The eStore product ID of the product that you want to sell is "1"

You can then create links using the following URL to allow someone to add item "1" to the shopping cart:

http://www.example.com/?wp_eStore_add_to_cart=1

Anyone who goes to the above URL will basically add item "1" to the shopping cart. Given you have the shopping cart shortcode placed somewhere on this page, the user will then be able to complete the checkout by clicking on the checkout button of the cart.

Lets say, you have a checkout/cart page and the URL of that page is the following:

http://www.example.com/checkout

You can then use the following URL to create your purchase link which will add item "1" to the cart and at the same time the user will go to the checkout/cart page:

http://www.example.com/checkout/?wp_eStore_add_to_cart=1

Creating an HTML Link

Here is an example code snippet that shows how you can use the technique learnt above to create an HTML text link:

<a href=http://www.example.com/?wp_eStore_buy_now=1>Click Here to Buy</a>

Creating an HTML Link with an Image

Here is an example code snippet that shows how you can use the technique learnt above to create an HTML link with an image (this image could be a nice BUY image):

<a href=http://www.example.com/?wp_eStore_buy_now=1><img src=http://www.example.com/url-of-the-image /></a>

Applying a Discount Coupon

You could apply a discount coupon to the cart automatically after adding the item via the link. Below is an example of how to create a link that will add an item then apply the supplied coupon code:

http://www.example.com/checkout/?wp_eStore_add_to_cart=1&discount_code=COUPONCODE

 

Using a Buy Now Type Behavior with Text Link

 

You can create links using the following URL to allow someone to purchase item "1" directly via PayPal without adding the item to the cart (avoiding the shopping cart altogether):

http://www.example.com/?wp_eStore_buy_now=1

 

Using a Subscription Type Behavior with Text Link

 

You can create links using the following URL to allow someone to purchase subscription item "1" directly via PayPal:

http://www.example.com/?wp_eStore_subscribe=1

 

Using a Donation Type Behavior with Text Link

 

You can create a link using the following URL to allow someone to donate:

http://www.example.com/?wp_eStore_donation=1

 

Specifying a Variation in the Link


You can pass a variation in the link too. Here is an example of how to pass a variation:

http://www.example.com/checkout/?wp_eStore_add_to_cart=1&variation1=red&variation2=medium

 

Specifying a Variation Price


You can pass a variation and a variation price in the link. Here is an example:

http://www.example.com/checkout/?wp_eStore_add_to_cart=1&variation1=red&var1_price=10

Lets say the price of product 1 is $20. When someone clicks the above link, it will charge them $30 total ($10 fro the variation).

 

Specifying a Custom Input


You can pass a custom input in the link like so:

http://www.example.com/checkout/?wp_eStore_add_to_cart=1&c_input="my custom input"

 

Buy Now Link for a Specific Gateway

 

Use the following if you wanted to create a buy now link for a gateway other than PayPal:

http://www.example.com/?wp_eStore_buy_now=1&gateway=2co

The following post has a list of available gateway values that you can use:
https://francontact.zendesk.com/hc/fr/articles/207745689

 

Applying Discount in the Cart via URL

 

The following documentation explains how to use this feature: https://francontact.zendesk.com/hc/fr/articles/208469065

Vous avez d’autres questions ? Envoyer une demande

Commentaires

Réalisé par Zendesk