Jump to content


Corporate Sponsors


Latest News: (loading..)

* * * * * 2 votes

Optional Related Products, Version 4.0


  • You cannot reply to this topic
416 replies to this topic

#401 sackling

  • Community Member
  • 256 posts
  • Real Name:robert stein

Posted 13 September 2011, 20:21

Never mind figured it out by moving the delete to only delete if the product categories ==0 like so:

if ($product_categories['total'] == '0') {
		    tep_remove_product($product_id);
    /* Optional Related Products (ORP) */
		  tep_db_query("delete from " . TABLE_PRODUCTS_RELATED_PRODUCTS . " where pop_products_id_master = '" . (int)$product_id . "'");
		  tep_db_query("delete from " . TABLE_PRODUCTS_RELATED_PRODUCTS . " where pop_products_id_slave = '" . (int)$product_id . "'");
	    //ORP: end
		  }


#402 vashichino7

  • Community Member
  • 213 posts
  • Real Name:Von Essaghol

Posted 15 October 2011, 19:40

Hey guys; i installed the related products and it works just fine expect when I go to edit a product I get a break stating the following:

Warning: reset() [function.reset]: Passed variable is not an array or object in /home/savingsh/public_html/admin/includes/classes/object_info.php on line 17

Warning: Variable passed to each() is not an array or object in /home/savingsh/public_html/admin/includes/classes/object_info.php on line 18


Here is what it says in object_info.php:

<?php
/*
$Id$

osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com

Copyright © 2003 osCommerce

Released under the GNU General Public License
*/

class objectInfo {

// class constructor
function objectInfo($object_array) {
reset($object_array);
while (list($key, $value) = each($object_array)) {
$this->$key = tep_db_prepare_input($value);
}
}
}
?>

Any ideas?

#403 vashichino7

  • Community Member
  • 213 posts
  • Real Name:Von Essaghol

Posted 19 October 2011, 21:52

Can this mod be used with 2.3.1 ??

#404 discxpress

  • Community Member
  • 301 posts
  • Real Name:Lecarl Butler
  • Gender:Male

Posted 20 October 2011, 09:28

View Postvashichino7, on 19 October 2011, 21:52, said:

Can this mod be used with 2.3.1 ??
Yes, download it here: http://addons.oscommerce.com/info/8057

#405 discxpress

  • Community Member
  • 301 posts
  • Real Name:Lecarl Butler
  • Gender:Male

Posted 20 October 2011, 09:38

Question. Is it possible to create some extra fields in Easy Populate so relations can be established by spreadsheet?

I have a large shop and it would seem easier to locate in excel and match the items. Or better yet match the products to all products in a certain category. I know that option was available in the other cross sell contributions for version 2.2. This is a great contribution and that's my idea for making it greater. If I was good at php I would attempt that feat myself.

Thanks for your time.

#406 dvharrison

  • Community Member
  • 321 posts
  • Real Name:Deb
  • Gender:Female
  • Location:Essex, UK

Posted 13 January 2012, 20:53

Hi

I have added Optional related Products on my XAMPP server to a website I plan to upgrade. SO far so good. But I get to Catalog > related products and on the SQL database.

And Whether I press the New Install SQL for Version 4 or the Upgrade SQL to Version 4, I get the following error:

Quote

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'TYPE=MyISAM' at line 7

CREATE TABLE IF NOT EXISTS `products_related_products` ( `pop_id` int(11) NOT NULL auto_increment, `pop_products_id_master` int(11) NOT NULL default '0', `pop_products_id_slave` int(11) NOT NULL default '0', `pop_order_id` smallint(6) NOT NULL default '0', PRIMARY KEY (`pop_id`) ) TYPE=MyISAM;

[TEP STOP]

I tried creating the table in SQL, doing it from scratch using the existing one I have.

Please could someone shed some light?? [img]http://forums.oscommerce.com//public/style_emoticons/default/unsure.png[/img]
Debbie Harrison

#407 dvharrison

  • Community Member
  • 321 posts
  • Real Name:Deb
  • Gender:Female
  • Location:Essex, UK

Posted 14 January 2012, 12:30

Is there a way I can manually add the SQL database? :blink:
Debbie Harrison

#408 dvharrison

  • Community Member
  • 321 posts
  • Real Name:Deb
  • Gender:Female
  • Location:Essex, UK

Posted 16 January 2012, 10:35

I have managed to override the SQL issues by changing TYPE=MYISAM; to ENGINE=MyISAM; and that now works. Sadly the product pages do not show. This isn't a new install for me as I had ORP on the old 2.2 site.

Please help whats happening??
Debbie Harrison

#409 dvharrison

  • Community Member
  • 321 posts
  • Real Name:Deb
  • Gender:Female
  • Location:Essex, UK

Posted 26 January 2012, 11:33

I have re-installed and the existing related products now tie up. However, I cannot view from Catalog > Related products, existing products and when I call an individual product, I don't get its record, I am asked to create a New one. Furthermore new ones do not show up.

I take it support has dried up on this once great contribution? Thats is a shame. :'(
Debbie Harrison

#410 gewoon09

  • Community Member
  • 19 posts
  • Real Name:michiel

Posted 01 February 2012, 16:02

Hi,

I've installed the contribution, but I cannot get it running. Everything in configuration is visible, no problem, but when I click catalogue>related products, I see this error:

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'RELATED_PRODUCTS_MAX_ROW_LISTS_OPTIONS' at line 8

SELECT pa.* FROM products_related_products pa LEFT JOIN products_description pd ON pa.pop_products_id_master = pd.products_id AND pd.language_id = '4' WHERE pd.products_id = '31' ORDER BY pd.products_name, pa.pop_order_id, pa.pop_id LIMIT 0, RELATED_PRODUCTS_MAX_ROW_LISTS_OPTIONS

On the live website likewise:
1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'RELATED_PRODUCTS_MAX_DISP' at line 14

SELECT pop_products_id_slave, products_name, products_model, products_price, products_quantity, products_tax_class_id, products_image FROM products_related_products, products_description pa, products pb WHERE pop_products_id_slave = pa.products_id AND pa.products_id = pb.products_id AND language_id = '4' AND pop_products_id_master = '31' AND products_status='1' ORDER BY rand() limit RELATED_PRODUCTS_MAX_DISP


In this thread, someone else had this problem, but didn't share the answer when fixed. Can anyone help me out? I have installed the osc 2.2 version.

Thank you!

Michiel

#411 Garrigue

  • Community Member
  • 19 posts
  • Real Name:Weicherding

Posted 07 February 2012, 15:57

Hello,

Sorry for my bad English.

I added the contribution "Related products" tailored to Cso 2.3.1
I have the admin configuration menu (Related products).
I have the category menu BOX_CATALOG_CATEGORIES_RELATED-PRODUCTS that installs configuration menu (Related products).

And now what do I do? I see nothing in the various menus (products, product attributes, etc.) for create relationships between products.

Can someone enlighten me please.

#412 Garrigue

  • Community Member
  • 19 posts
  • Real Name:Weicherding

Posted 08 February 2012, 10:40

For clarity, when I'm on a product, I should have a button "Add related products" next to the other buttons: "modify", "delete", "move" and "copy".

But i have an new button entitled him "IMAGE_RELATED_PRODUCTS" and when i clic he going to the screen Utility installation / uninstall SQL tables (HEADING_TITLE_ORP), whereas previously I installed the SQL.

Strange !

#413 ShaGGy

  • Community Member
  • 59 posts
  • Real Name:Les

Posted 22 February 2012, 21:53

Can anyone point me to what changes need making to get it to write the products_model in the db instead of the product_id ?

I can see its $products_id_master &$products_id_slave but cannot see where product_id is assigned to these ?

#414 dvharrison

  • Community Member
  • 321 posts
  • Real Name:Deb
  • Gender:Female
  • Location:Essex, UK

Posted 02 March 2012, 10:41

Hi all, I have added this to my live site, but as you can see from http://www.kelscrafts.co.uk/product_info.php?products_id=858 The related products are nowhere to be seen.

I have gone through the changes and uploads with a fine tooth comb. Please could anyone help me please??

Also on the admin section, the page links do not work the url (eg page 15) appear but not the actual content of page 15.

Please can anyone advise? TIA
Debbie Harrison

#415 GMcSwegan

  • Community Member
  • 6 posts
  • Real Name:G McSwegan

Posted 30 March 2012, 15:11

I was wondering if it there is a simple fix to output the related products into a carousel rather into a table?

Thanks in advance

#416 Brainbug125

  • Community Member
  • 44 posts
  • Real Name:bob

Posted 23 April 2012, 10:02

View Postnanuk982, on 23 February 2010, 19:45, said:

Hi all!!!

Great contribution, works fine but I have just one problem, hoping someone could help me to get it through.

I can't get appear the right price on products which have a special or discount price.

Same problem here :(

I just testing Xsell too... I found that this contrib (Related Products) is more flexible but...but... what about prices?
Xsell Displays Correctly...
Do u have a solution?

#417 Brainbug125

  • Community Member
  • 44 posts
  • Real Name:bob

Posted 23 April 2012, 10:38

Opsss...problem was in xsell and not in this contribution....
Xsell still kept an old Special product in cache.

Now Price is displaying correctly

Need to test more tought