cancel
Showing results for 
Search instead for 
Did you mean: 

Adding checkbox to individual products

Adding checkbox to individual products

We have some products with complex shipping parameters and would like to add a box to agree to the extra terms and conditions. This would be on the individual product page and ideally have a hyperlink to the conditions. So far we have only been able to have the check box as a customizable option. This did not read code and left it as text(for the link) and does not seem to have a way to have more than a sentence or two. 

 

We have an extension for adding files that can be downloaded, but this is at the bottom of the product page and not when they add to cart. We want something obvious that will catch the customer's eyes. It also should be required before adding it to the cart.

 

Any ideas on what else to try? Thanks in advance for all of your help!

 

2 REPLIES 2

Re: Adding checkbox to individual products

Hello @oliveabuil6232 

 

1. You can create a new product attribute as "terms and conditions" and you can set 1 for those products which required.

2. Then you can create a hyperlink based on that product attribute, you can create hyperlink like this :

https://community.magento.com/t5/Magento-2-x-Programming/I-want-to-check-with-one-condition-before-a...

just before the hyperlink code, you must add condition if that product's "terms and conditions" is 1 then the show terms and condition.

3. you can either prevent add to cart button to be clicked or you can stop execution of adding product to cart by JS if that checkbox is not filled.

 

Hope it helps !

Problem Solved ? Click on 'Kudos' & Accept as Solution ! Smiley Happy

Re: Adding checkbox to individual products

Hello @oliveabuil6232,

As an option, this can be achieved with the help of the Advanced Product Options extension, and look as follows on the front-end: https://prnt.sc/vp25wg

 

---------------------------------------------------------

If you find our answer useful, please give 'Kudos' or 'Accept as Solution'.