Advertisement
Guest User

Untitled

a guest
Dec 25th, 2015
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.17 KB | None | 0 0
  1. $category_info = $this->model_catalog_product->getProductCategory($result['product_id']);
  2.                     if($category_info==false){$category_id2 = "0";}else{
  3.                         $category_name2 = $category_info[0]['category_name'];
  4.                         $category_id2 = $category_info[0]['category_id'];
  5.                         $this->data['categories2'][$category_info[0]['category_id']] = array(
  6.                             'name' => $category_info[0]['category_name'],
  7.                             'link' => $this->url->link('product/category', 'path=' . $category_info[0]['category_id']),
  8.                             );
  9.                     }
  10.                            
  11.                 if(!isset($products_array2[$category_id2])){$products_array2[$category_id2] = array();}
  12.                 $products_array2[$category_id2][] = array(
  13.                     'product_id' => $result['product_id'],
  14.                     'thumb'      => $image,
  15.                     'name'       => $result['name'],
  16.                     'price'      => $price,
  17.                     'price_byr'  => $price_byr,
  18.                     'special'    => $special,
  19.                     'special_byr'=> $special_byr,
  20.                     'rating'     => $rating,
  21.                     'reviews'    => sprintf($this->language->get('text_reviews'), (int)$result['reviews']),
  22.                     'href'       => $this->url->link('product/product', 'product_id=' . $result['product_id']),
  23.                     );
  24.                 $this->data['products2'] = $products_array2;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement