How to Fix: Product options appear twice and/or your dropdown opens and closes immediately

This is typically caused by a duplicate data-cg-product-form="1" attribute

If your product options appear twice in a dropdown or the dropdown briefly opens and immediately closes when clicked, your product form attribute may be configured more than once in the same area of the page.

This is typically caused by a duplicate data-cg-product-form="1" attribute.

Symptoms

You may notice one or more of the following:

  • Each product option appears twice in the option dropdown

  • Clicking an option dropdown opens it and then immediately closes it

  • Product options behave inconsistently

  • The Add to Cart button does not work as expected

What to check

In your Webflow product template, search for:

data-cg-product-form="1"

This attribute should appear only once for each individual product form.

If it is applied to a main product-form container and also to an element nested inside that container, CartGenie will recognize both elements as separate product forms. This can initialize the same option selector twice, resulting in duplicate options and conflicting click behavior.

How to fix it

  1. Open the product template in Webflow.

  2. Find the main element using data-cg-product-form="1".

  3. Check all elements inside it for another data-cg-product-form="1" attribute.

  4. Remove the attribute from the nested element (keep the wrapper attribute).

  5. Keep data-cg-product-form="1" only on the main product-form container.

  6. Publish your site.

After publishing, each option should appear once and the dropdown should open normally.

Why this affects the Add to Cart button

If the Add to Cart button is inside both nested product-form elements, CartGenie may also attempt to connect that button to two product forms. Removing the duplicate attribute ensures CartGenie initializes the product options and Add to Cart behavior only once.

Did this answer your question?
😞
😐
😁