I've added the WooCommerce shortcode "add_to_cart" successfully on a custom post type page.
[add_to_cart id="510"]
If there is nothing in the cart, it redirects to the shopping cart adding the product as intended. However, if the product is already in the cart and the user click the button on the custom post type page, it redirects back to itself.
The user can't add more than one of a given item to the cart. How can I check to see what's in the cart, so that if the user clicks the button it will redirect to the shopping cart if that product is already in there? Don't need any error message to come up like on the standard WooCommerce product page.
Thanks in advance for any ideas!
Aaron