Jump to content



Latest News: (loading..)

- - - - -

checkbox in product_info

checkbox attributes

This topic has been archived. This means that you cannot reply to this topic.
1 reply to this topic

#1   asher1981

asher1981
  • Members
  • 11 posts

Posted 03 December 2011 - 10:19 PM

Hi,

I did some changes on product_info, so that customers are able to choose some attributes from drop_down and some others from checkboxes.

Everything works fine, the only problem I have, is that if 2 options from the same attribute are cheked by checkbox, only the last option is saved. So just an example:

We have a shirt that can have printet a design on it.
There are 3 different colors for a shirt (white, blue and black). These options are available in a dropdownlist.
We can print on the shirt on the front-side and/or on the backside. These options are choosen by checkbox.

If the the customer now choses front and back-side, only backside is added as choosen attribute.


In application_top.php the attributes are added by $HTTP_POST_VARS['id']  I think. How can I also add the second checkbox option to the shopping_cart??

Thanx in advance.

#2   asher1981

asher1981
  • Members
  • 11 posts

Posted 03 December 2011 - 10:31 PM

Now I see the problem:

$HTTP_POST_VARS['id'] takes the option Id of the attribute. So all checkbox options of one attribute have the same 'id'... so $HTTP_POST_VARS['id']
only recognisez the last id of this attribute. But in shopin_cart I need this Id to list the options and calculate the prices.

Does anyone has an Idea for a workaround??