Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

osRainMan

Pioneers
  • Posts

    1
  • Joined

  • Last visited

Profile Information

  • Real Name
    ROland

osRainMan's Achievements

  1. Hi, felt it was time to contribute something in return for using osCommerce since a number of years. Concerns the piwik addon in 2.3.4 BS. Checking the reporting in PiWiK I noticed that product category is always the same, irrespective of the product concerned. Checking the code in ht_piwik.php I noticed a potential bug in line 57. This line contains the PHP code to establish the product name and product category. The current version doesn't properly join the products and products2categories tables which results in a random category name. Adding 'and p.products_id = p2c.products_id' to the MySQL query solves this problem. After inserting this the line 57 looks like $products_query = tep_db_query("select p.products_id, pd.products_name, cd.categories_name from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, ". TABLE_CATEGORIES_DESCRIPTION ." cd WHERE p.products_id = pd.products_id and p.products_id = p2c.products_id and p2c.categories_id = cd.categories_id and p.products_id = " . (int)$HTTP_GET_VARS['products_id'] . " and pd.language_id ='" . (int)$languages_id . "' and cd.language_id ='".(int)$languages_id."'"); P.S: Couldn't find a topic related to PiWiK that I could use.
×
×
  • Create New...