4 min read • Updated 4 hours ago
Manage products with Webstudio CMS
Use Webstudio CMS to manage your product data and pages.
Overview
This article will walk you through creating an add to cart form and binding it to Webstudio CMS data.
This article assumes you have already completed the following in Webstudio:
Set up a CMS (at minimum, you'll need a field for product name and product price)
By the end of this article, you will have completed the following:
Create an add to cart form in Webstudio
Bind dynamic CMS / product data to the add to cart form
Add Code Snippet
Create Add To Cart Form
Add Product Data & Fields
At minimum, Foxy just needs a product name and price. This can be dynamic data from CMS data, static, or a mix of both dynamic and static. In addition, you can pass any other hidden, visible, or configurable data.
Name (required)
Price (required)
Code (aka SKU) (optional)
Image (optional)
Quantity (optional)
By default, a quantity of 1 will be added to cart. Once a product is in the cart, customers can easily change the quantity. If you'd like to allow customers to specify a quantity before adding a product to cart, please follow the steps below:
Custom (optional)
In addition to standard Foxy parameters like name and price, you can add any other preset or configurable fields (ie: size, color, format, etc.). Any hidden or visible field with a value, will be included in the product info in cart.
Update Inventory Count
Using Foxy Automations, Make, Zapier, Pipedream or similar automation tools, you can create an automation to auto-update your product inventory count in your data source, after each successful Foxy transaction.
Testing
To test your add to cart forms, simply publish your Webstuio site and navigate to one of your product pages. Click to add product to cart. You should see product information and image (when applicable) in cart.
Limitations
Currently, this approach does not support CMS driven product variants. That said, you can have static/preset product variants (ie: a select field with size options). We're still working on this, but if you have a need for dynamic variant support, please let us know.