Jump to content
  • разработка интернет магазинов на opencart
  • доработка интернет магазинов на opencart

Dead

Новичок
  
  • Posts

    3
  • Joined

  • Last visited

Dead's Achievements

Newbie

Newbie (1/14)

  • Conversation Starter
  • First Post
  • Week One Done
  • One Month Later
  • One Year In

Recent Badges

0

Reputation

  1. Добрался в /catalog/controller/product/category.php Вот часть кода, которая формирует данные о товаре. $this->data['products'][] = array( 'name' => $result['name'], 'model' => $result['model'], 'rating' => $rating, 'stars' => sprintf($this->language->get('text_stars'), $rating), 'thumb' => $this->model_tool_image->resize($image, $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height')), 'price' => $price, 'stk' => $result['stk'], 'options' => $options, 'special' => $special, // 'href' => $this->model_tool_seo_url->rewrite(HTTP_SERVER . 'index.php?route=product/product&path=' . $this->request->get['path'] . '&product_id=' . $result['product_id']), 'href' => $this->model_tool_seo_url->rewrite(HTTP_SERVER . 'index.php?route=product/product&product_id=' . $result['product_id']), 'add' => $add ); } А вот часть кода, которая формирует ЧПУ: Ситуация икая, если я перехожу в категорию у меня им выводятся не только субкатегории, но ик же и товары из этот категории, ик вот если раскомментировать закомментированную строчку, то в категориях товары в урле не будут иметь субкатегорий. Т.е допустим товар принадлежит к категории cat1 и субкатегории sub1, в категориях этот товар бугдет иметь вид А нужно чтоб имел
  2. Спасипотому что. Есть шиблон category.tpl в нем можно использовать переменную пхп $products(array) как можно туда добавить элемент, который бы согдержал строку вида category/subcategory/ ггде category - категория товара, subcategory - субкатегория товара?
  3. В данный момент категории имеют вид: site.ru/category/ site.ru/category/subcategory/ Товары имеют вид site.ru/product1.html Субкатегории есть не во всех категориях. Как привести урл товара к виду, если есть субкатегории: site.ru/category/subcategory/product1.html Соответственно, если нету то к виду: site.ru/category/product1.html
×
×
  • Create New...

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.