This is a discussion on adding multiple manufacturers to products within the osCommerce 2.2 Modification Help forums, part of the osCommerce 2.2 Forums category; Is there a way to have more than one manufacturer attached to a product? I've changed the "manufacturer" to "Authors", ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Is there a way to have more than one manufacturer attached to a product? I've changed the "manufacturer" to "Authors", but several of our products are collaborations and I would like it so that the product page will display all its contributors, and for the product to appear in the search for each of its authors. Any suggestions? |
|
#2
| ||||
| ||||
| Hi, You could always put the names of all the authors on the product page in the description.
__________________ Michael Sasek osCMax Developer
|
|
#3
| |||
| |||
| Well, here's what I've got thus far... I've added a 2nd manufacturer id to my products and now when you go to the product page both manufacturers are listed in the right column. The only issue I'm having now is getting the all the products to show up on each manufacturer's search page. I'm pretty sure that my solution lies in altering the defult.php code. I can change it to display products for either the 1st id or the 2nd, but not both at the sametime - which is what I want. here's the line of code... (starting appx at line 172) Code: // show the products of a specified manufacturer
* *if (isset($HTTP_GET_VARS['manufacturers_id'])) {
* * *if (isset($HTTP_GET_VARS['filter_id'])) {
// We are asked to show only a specific category
* * * *$listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . $HTTP_GET_VARS['manufacturers_id'] . "' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . $languages_id . "' and p2c.categories_id = '" . $HTTP_GET_VARS['filter_id'] . "'";
* * *} else {
// We show them all
* * * *$listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and pd.products_id = p.products_id and pd.language_id = '" . $languages_id . "' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . $HTTP_GET_VARS['manufacturers_id'] . "'";
* * *}
Code: p.manufacturers_id = m.manufacturers_id Code: p.manufacturers2_id = m.manufacturers_id |
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| New products page.... Multiple columns | jdlev77 | osCommerce 2.2 Discussion | 4 | 08-27-2005 07:47 PM |
| Temporarily inactivate multiple manufacturers? | A2ZBob | osCommerce 2.2 Modification Help | 1 | 12-10-2004 09:18 AM |
| Multiple Catagories and Adding Fields | Lalla | osCommerce 2.2 Modification Help | 5 | 02-20-2004 04:19 AM |
| Modify Manufacturers Box to only show Manufacturers that are | elemar | osCommerce 2.2 Modification Help | 0 | 12-09-2003 01:16 AM |
| Contribution for adding multiple products | jacven | osCommerce 2.2 Modification Help | 3 | 10-22-2003 07:23 AM |