Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The link will take you to the checkout page with that product added to the shopping cart with quantity 1.

If your product has variants then use “products” instead of “productId”. Then add both productId and variantDetailId separated by a period, a colon, and the quantity.

Code Block
<a href="https://yourwebsite.com/checkout/?products=12.142:1">Add to Cart</a>


This method is intended to be used with a separate checkout page than your WooCommerce checkout page.

...