Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Options not being added to orders...


Guest

Recommended Posts

Help!!!

 

I am working on my store and some of my products have many options. When I go to product_info.php page for the item, I see all of the options and have no problems selecting and changing them...

 

The problem is when I add the order to the cart, I get none of the options. and when I search the source code orders_products_attributes never comes up...

 

Am I missing something????

 

Please help!!!

 

Rob

Link to comment
Share on other sites

Rob,

 

Have you added any contributions that are related to options or affected the product_info.php or shopping cart pages?

 

ed

 

Nope.. But I do see where the stuff is being added. The only thing that I did was add some fields to the attribues structure. But none of the should be taken when the item is purchased. THey are some graphics and extra info fields...

 

I see the

      // customer adds a product from the products page
     case 'add_product' :    if (isset($HTTP_POST_VARS['products_id']) && is_numeric($HTTP_POST_VARS['products_id'])) {
                               $cart->add_cart($HTTP_POST_VARS['products_id'], $cart->get_quantity(tep_get_uprid($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['id']))+1, $HTTP_POST_VARS['id']);
                             }
                             tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters)));
                             break;

 

The question is where does the 'id' field get set?

Link to comment
Share on other sites

I just realized th problem...

 

In the product_info.php I modified the line:

 

              <td class="main"><?php echo tep_draw_pull_down_menu('id_' . $products_options_name['products_options_id'], $products_options_array, $selected_attribute); ?></td>

 

I changed the id['... to be id_ because I have added a link next to the popup menu when opens a details of that attribute and I could not get the reference to work using 'id[1]' as the field in the form....

 

This is the code for the link...

	<td class="main"><?php echo '<a href="#" onClick="return ShowDetails(\'' . tep_href_link(FILENAME_POPUP_DETAILS) . '?pID=\' , document.forms.cart_quantity.' . 'id_' . $products_options_name['products_options_id'] . '.options[document.forms.cart_quantity.' . 'id_' . $products_options_name['products_options_id'] . '.selectedIndex].value)";>' .  TEXT_CLICK_4_INFO . '</a>'; ?></td>

 function ShowDetails(URL, whichItem){
URL+=whichItem;
popupWindow(URL);
return false;
}

 

Maybe there is some way to make this work putting the id back to an array...

 

Rob

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...