Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Checkbox doesn't work


Recommended Posts

I installed the products options contribute, but the checkboxes don't work. It only will show one checkbox.


What I'm trying to do is give the selection for amounts on gift certificates. I want it an option for each denomination, and checkboxes would work so they can choose more than one at a time. IE: I have $5, $10, $20, $50. If they want $25 gift cert. then they can choose $5 and $20... but only one checkbox appears.


Here's the code on the product_info page where it does the logic (I believe the problem is there):


           //CLR 030714 Add logic for checkboxes
           $products_attribs_query = tep_db_query("select distinct patrib.options_values_id, patrib.options_values_price, patrib.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = '" . $products_options_name['products_options_id'] . "'");
           $products_attribs_array = tep_db_fetch_array($products_attribs_query);
           echo '<tr><td class="main">' . $products_options_name['products_options_name'] . ': </td><td class="main">';
           echo tep_draw_checkbox_field('id[' . $products_options_name['products_options_id'] . ']', $products_attribs_array['options_values_id']);
           echo $products_options_name['products_options_comment'];
           if ($products_attribs_array['options_values_price'] != '0') {
             echo '(' . $products_attribs_array['price_prefix'] . $currencies->display_price($products_attribs_array['options_values_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) .') ';
           echo '</td></tr>';


Thank you for any responses.... I'm on a time crunch and have already spent several hours trying to find answers.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...