Guest Posted March 11, 2008 Posted March 11, 2008 If I add a second manufacturer (manufacturers2_id) to the products table, how would I get the second manufacturer to display in index.php? I sell coffee and want to sort it by region but the coffee in blends is usually from more than one region so I want it to display on both the lists.
photofxplus Posted March 11, 2008 Posted March 11, 2008 The question is, how would you add a second manufacturer to a product? The products table takes the manufacturer as manufacturer_id, so you would have to create a third manufacturer that would represent both. Such as if one product was - 'product' and had two manufacturers - 'man1' and 'man2' then create a new maufacturer as 'man1-man2'. Associate this created manufacturer with the product on the products attribute page then do a str_search() '-' on the returned manufacterer name. Separate the two, then another db query would return the manufacturer_id for each.. Or manually create an array that would associate the products with different manufacterers: array('product_id' => 'manufacterer_id', 'manufacterer_id')); Either way you would have to edit the index file to display in html.. Lloyd
Guest Posted March 12, 2008 Posted March 12, 2008 Thanks for the response but that solution is way above my head .... so I looked at the problem again but not by using the Manufacturers Box but with using the Categories box and I came up with a solution. I posted it in the Tips and Tricks section. http://www.oscommerce.com/forums/index.php?showtopic=295891
Recommended Posts
Archived
This topic is now archived and is closed to further replies.