# Show purchase buttons in template files with edd_get_purchase_link()

 You can manually display a purchase link for any product by using the *edd\_get\_purchase\_link()* function. This will output the purchase options for the specified product.

 In its simplest form, the function can be used like this:

```
echo edd_get_purchase_link( array( &#039;download_id&#039; =&gt; 37 ) );
```

 If the specified product has [variable prices](https://easydigitaldownloads.com/docs/variable-prices/) enabled, the price options will be displayed above the purchase button.

 The function takes a number of possible arguments:

- *download\_id* - The ID number of the product to show a purchase link for
- *price* - TRUE/FALSE whether or not to show the price on the button
- *direct* - TRUE/FALSE whether to create a &quot;Buy Now&quot; button or an &quot;Add to Cart&quot; button. Set to TRUE for a buy now behavior
- *text* - The text to show on the button
- *style* - button/plain the style of link to show
- *color* - The color of the button to show
- *class* - Custom class to add to the button wrapper element