Create a Purchase Button
In this article we'll show you how to use Carrd's button element to create a Foxy purchase option.

In this article
Add Foxy Code Snippet
To display the sidecart when a customer adds a product to cart and to store customer sessions, Foxy's code snippet must be added to a hidden embed element in your Carrd website.
- 1
- In the Foxy dashboard, go to the Sample Code page.
- 2
- On the Sample Code page, copy the snippet of code from Step 1.
- 3
- In Carrd, click on the "Add an element" icon.
- 4
-
From the elements menu, click on the "Embed" option.
- 5
-
In the Embed panel, set the "Style" to "Hidden".
- 6
-
Paste the snippet of code you just copied into the "Code" field.
- 7
-
Click on the "Done" button to save your changes.
Link Button Element
- 1
-
In Carrd, select your purchase button to load the Buttons panel.
- 2
- Go to the Foxy Sample Code page to get a sample purchase link.
- 3
-
From the Step 2 section, copy the link example
href
value. - 4
-
In Carrd, paste the link you just copied into the "URL" field.
- 5
- Modify the product parameters as needed. More information about product parameters can be found in our wiki here.
- 6
- Click on "Done" to save your changes.
- 7
- Click on the "Save" icon to display the Publish panel.
- 8
- Scroll down and click on the "Publish Changes" button.
- 9
- Test your purchase button to ensure it works as expected.