-
Публікації
18 -
З нами
-
Відвідування
Інформація
-
Стать
Мужчина
Відвідувачі профілю
Блок відвідувачів профілю відключений і не буде доступний широкому іншим користувачам
VladimirIvanov's Achievements
-
VladimirIvanov підписався на usergio
-
Категории уже назначил, но фото не могу прописать... может кто сталкивался или может есть решение? потому что стандартное решение не работает на форумах ютуб перепробовал но конкретно под unishop те методы не работают
- 15 105 відповідей
-
- адаптивный
- универсальный
- (і ще %d)
-
Мне нужно вивести для самого меню вот так на фото категории:
- 15 105 відповідей
-
- адаптивный
- универсальный
- (і ще %d)
-
Не могу прописать вивод картинки в меню тема unishop нужно прописать для подкатегорий меню картинку в файле header.php (путь: catalog\controller\common\header.php) подключил $this->load->model('tool/image'); создал и записал в масив foreach ($children as $child) { $filter_data = array( 'filter_category_id' => $child['category_id'], 'filter_sub_category' => true ); if ($child['image']) { $cat_image = $this->model_tool_image->resize($child['image'); } else { $cat_image = ''; } $children_data[] = array( 'name' => $child['name'] . ($this->config->get('config_product_count') ? ' (' . $this->model_catalog_product->getTotalProducts($filter_data) . ')' : ''), 'thumb' => $cat_image, 'href' => $this->url->link('product/category', 'path=' . $category['category_id'] . '_' . $child['category_id']) ); } далее в файле header.tpl (путь: catalog\view\theme\unishop\template\common\header.tpl) прописал картинку: <img src="<?php echo $child['thumb']; ?>" alt="<?php echo $child['name']; ?>"> весь файл header.tpl (путь: catalog\view\theme\unishop\template\common\header.tpl) : <!DOCTYPE html> <html dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>"> <head> <title><?php echo $title; ?></title> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <base href="<?php echo $base; ?>" /> <?php if ($show_meta_robots) { ?> <meta name="robots" content="noindex, follow" /> <?php } ?> <?php if ($description) { ?> <meta name="description" content="<?php echo $description; ?>" /> <?php } ?> <?php if ($keywords) { ?> <meta name="keywords" content= "<?php echo $keywords; ?>" /> <?php } ?> <meta property="og:title" content="<?php echo $title; ?>" /> <meta property="og:type" content="website" /> <?php if (isset($og_url)) { ?> <meta property="og:url" content="<?php echo $og_url; ?>" /> <?php } ?> <?php if (isset($og_image)) { ?> <meta property="og:image" content="<?php echo $og_image; ?>" /> <?php } else { ?> <meta property="og:image" content="<?php echo $logo; ?>" /> <?php } ?> <meta property="og:site_name" content="<?php echo $name; ?>" /> <?php foreach ($links as $link) { ?> <link href="<?php echo $link['href']; ?>" rel="<?php echo $link['rel']; ?>" /> <?php } ?> <link href="catalog/view/javascript/bootstrap/css/bootstrap.min.css" rel="stylesheet" media="screen" /> <link href="catalog/view/theme/unishop/stylesheet/stylesheet.css?v=2.5.0.0" rel="stylesheet" type="text/css" media="screen" /> <link href="catalog/view/theme/unishop/stylesheet/font-awesome.min.css" rel="stylesheet" type="text/css" media="screen" /> <link href="catalog/view/theme/unishop/stylesheet/elements_<?php echo $store_id; ?>.css?<?php echo $save_date; ?>" rel="stylesheet" type="text/css" media="screen" /> <?php foreach ($styles as $style) { ?> <link href="<?php echo $style['href']; ?>" type="text/css" rel="<?php echo $style['rel']; ?>" media="<?php echo $style['media']; ?>" /> <?php } ?> <?php if ($background_image) { ?> <link href="catalog/view/theme/unishop/stylesheet/background.css" rel="stylesheet" type="text/css" media="screen" /> <?php } ?> <?php if ($custom_style) { ?> <link href="catalog/view/theme/unishop/stylesheet/<?php echo $custom_style; ?>" rel="stylesheet" type="text/css" media="screen" /> <?php } ?> <?php if ($user_css) { ?> <style><?php echo $user_css; ?></style> <?php } ?> <script>if(!localStorage.getItem('display')) {localStorage.setItem('display', '<?php echo $default_view; ?>');}</script> <script src="catalog/view/javascript/jquery/jquery-2.1.1.min.js"></script> <script src="catalog/view/javascript/bootstrap/js/bootstrap.min.js"></script> <script src="catalog/view/theme/unishop/js/common.js"></script> <?php foreach ($scripts as $script) { ?> <script src="<?php echo $script; ?>"></script> <?php } ?> <?php if ($user_js) { ?> <script><?php echo $user_js; ?></script> <?php } ?> <?php foreach ($analytics as $analytic) { ?> <?php echo $analytic; ?> <?php } ?> <?php if ($categories) { ?> <?php if ($menu_type == 1 && $menu_expanded) { ?> <?php $one_line = $two_line = 0; ?> <?php foreach($categories as $category) { ?> <?php if (mb_strlen($category['name']) <= 33) { ?> <?php $one_line++; ?> <?php } else { ?> <?php $two_line++; ?> <?php } ?> <?php } ?> <?php if($uni_home) { ?> <?php $total = (($one_line * 40) + ($two_line * 60)) + 9; ?> <?php } else { ?> <?php $total = (($one_line * 40) + ($two_line * 60)) - 30; ?> <?php } ?> <style> @media (min-width:992px) { #column-left {margin-top:<?php echo $total; ?>px} #menu {border-radius:4px 4px 0 0} #menu .navbar-collapse {display:block !important} } </style> <?php } ?> <?php } ?> </head> <body class="<?php echo $class; ?>"> <nav id="top"> <div class="container"> <div class="pull-right"> <div id="account" class="btn-group"> <button class="btn btn-link dropdown-toggle" data-toggle="dropdown"> <i class="fa fa-user"></i> <span class="hidden-xs"><?php echo $logged ? $customer_name : $text_account; ?></span> <i class="fa fa-caret-down"></i> </button> <ul class="dropdown-menu dropdown-menu-right"> <?php if ($logged) { ?> <li><a href="<?php echo $account; ?>"><?php echo $text_account; ?></a></li> <li><a href="<?php echo $order; ?>"><?php echo $text_order; ?></a></li> <li><a href="<?php echo $transaction; ?>"><?php echo $text_transaction; ?></a></li> <li><a href="<?php echo $download; ?>"><?php echo $text_download; ?></a></li> <li><a href="<?php echo $logout; ?>"><?php echo $text_logout; ?></a></li> <?php } else { ?> <li><a <?php if($show_register) { ?>onclick="register();"<?php } else { ?>href="<?php echo $register; ?>"<?php } ?> ><?php echo $text_register; ?></a></li> <li><a <?php if($show_login) { ?>onclick="login();"<?php } else { ?>href="<?php echo $login; ?>"<?php } ?>><?php echo $text_login; ?></a></li> <?php } ?> </ul> </div> </div> <?php echo $language; ?> <?php echo $currency; ?> <?php if($headerlinks) { ?> <div id="top-links" class="hidden-xs hidden-sm"> <ul> <?php foreach ($headerlinks as $headerlink) { ?> <li><a href="<?php echo $headerlink['link']; ?>" title="<?php echo $headerlink['title']; ?>"><?php echo $headerlink['title']; ?></a></li> <?php } ?> </ul> </div> <div id="top-links2" class="btn-group pull-left visible-xs visible-sm"> <button class="btn btn-link dropdown-toggle" data-toggle="dropdown"><i class="fa fa-info"></i> <i class="fa fa-caret-down"></i></button> </div> <?php } ?> </div> </nav> <header> <div class="container"> <div class="row"> <div class="col-xs-12 col-sm-6 col-md-3 col-lg-3"> <div id="logo"> <?php if ($logo) { ?> <?php if (isset($og_url) && $home == $og_url) { ?> <img src="<?php echo $logo; ?>" title="<?php echo $name; ?>" alt="<?php echo $name; ?>" class="img-responsive" /> <?php } else { ?> <a href="<?php echo $home; ?>"><img src="<?php echo $logo; ?>" title="<?php echo $name; ?>" alt="<?php echo $name; ?>" class="img-responsive" /></a> <?php } ?> <?php } ?> </div> </div> <div class="col-xs-9 col-sm-4 col-md-3 col-md-push-5"> <div id="phone"> <div class="phone dropdown-toggle pull-right" data-toggle="dropdown"> <div><i class="fa fa-phone"></i> <span><?php echo $telephone; ?></span> <i class="fa fa-chevron-down hidden-xs"></i></div> <div><?php echo $delivery_hours; ?></div> </div> <?php if ($phones || $text_in_add_contacts) { ?> <ul class="dropdown-menu dropdown-menu-right"> <?php if($callback) { ?><li><a onclick="callback();" class="open_callback"><span class="hidden-xs"><?php echo $lang_1['text_header_callback']; ?></span><?php echo $lang_1['text_header_callback1']; ?></a></li><?php } ?> <?php if($text_in_add_contacts_position && $text_in_add_contacts) { ?><li class="text"><hr style="margin-top:0px;" /><?php echo $text_in_add_contacts; ?><hr style="margin-bottom:5px;" /></li><?php } ?> <?php foreach ($phones as $phone) { ?> <li> <a <?php if($phone['type']) { echo 'href="'.$phone['type'].'"';} ?>> <i class="<?php echo $phone['icon']; ?>"></i> <span><?php echo $phone['number']; ?></span> </a> </li> <?php } ?> <?php if(!$text_in_add_contacts_position && $text_in_add_contacts) { ?><li class="text"><hr style="margin-top:5px;" /><?php echo $text_in_add_contacts; ?></li><?php } ?> </ul> <?php } ?> </div> </div> <div class="col-xs-3 col-sm-2 col-md-1 col-md-push-5"><?php echo $cart; ?></div> <div id="div_search" class="col-xs-12 col-sm-6 col-md-4 col-lg-5 hidden-sm col-md-pull-4"><?php echo $search; ?></div> </div> </div> <div class="container"> <div class="row"> <?php if ($categories) { ?> <?php if ($menu_type == 1) { ?> <div class="col-sm-12 col-md-8 col-lg-9 col-xl-16 col-md-push-4 col-lg-push-3 col-xl-push-2"> <ul class="menu_links"> <?php foreach($headerlinks2 as $headerlink) { ?> <li> <a href="<?php echo $headerlink['href']; ?>" title="<?php echo $headerlink['name']; ?>"> <?php if(strpos($headerlink['icon'], 'fa-')) { ?> <span><i class="<?php echo $headerlink['icon']; ?>"></i></span> <?php } elseif ($headerlink['icon']) { ?> <span><img src="../image/<?php echo $headerlink['icon']; ?>" alt="" /></span> <?php } ?> <?php echo $headerlink['name']; ?> </a> </li> <?php } ?> </ul> <script>uniUpdRightMenu('.menu_links');</script> </div> <?php } ?> <div class="<?php echo $menu_type == 1 ? 'col-sm-6 col-md-4 col-lg-3 col-xl-4 col-md-pull-8 col-lg-pull-9 col-xl-pull-8' : 'col-sm-6 col-md-12 col-lg-12'; ?>"> <nav id="menu" class="<?php echo $menu_type == 2 ? 'menu2' : ''; ?> navbar"> <div class="navbar-header"> <span id="category"><?php echo $text_menu; ?></span> <button type="button" class="btn-navbar navbar-toggle" data-toggle="collapse" data-target=".navbar-ex1-collapse"><i class="fa fa-bars" aria-hidden="true"></i></button> </div> <div class="collapse navbar-collapse navbar-ex1-collapse"> <ul class="nav navbar-nav"> <?php foreach($categories as $category) { ?> <li <?php echo $category['children'] ? 'class="has-children"' : ''; ?> > <a <?php echo (isset($category['disabled']) && $category['disabled'] != '') ? 'class="disabled"' : 'href="'.$category['href'].'"'; ?>> <?php if(isset($category['icon'])) { ?> <?php if(strpos($category['icon'], 'fa-')) { ?> <span><i class="<?php echo $category['icon']; ?>"></i></span> <?php } elseif ($category['icon']) { ?> <span><img src="../image/<?php echo $category['icon']; ?>" alt="" /></span> <?php } ?> <?php } ?> <?php echo $category['name']; ?> <?php echo $category['children'] ? '<i class="fas fa-angle-down fa-fw"></i>' : ''; ?> </a> <?php if($category['children']) { ?> <span class="dropdown-toggle visible-xs visible-sm"><i class="fa fa-plus" aria-hidden="true"></i><i class="fa fa-minus" aria-hidden="true"></i></span> <div class="dropdown-menu column-<?php echo $category['column']; ?>"> <div class="dropdown-inner row"> <?php foreach($category['children'] as $child) { ?> <ul class="list-unstyled <?php echo $category['column'] ? 'col-sm-'.(12/$category['column']) : ''; ?>"> <li> <a <?php echo (isset($child['disabled']) && $child['disabled'] != '') ? 'class="disabled"' : 'href="'.$child['href'].'"'; ?>><i class="fas fa-angle-right"></i><?php echo $child['name']; ?></a> <img src="<?php echo $child['thumb']; ?>" alt="<?php echo $child['name']; ?>"> </li> </ul> <?php } ?> </div> </div> <?php } ?> </li> <?php } ?> </ul> </div> </nav> <?php if($menu_type == 2) { ?><script>uniUpdRightMenu('#menu.menu2 .nav');</script><?php } ?> </div> <?php } ?> <div id="div_search2" class="col-xs-12 col-sm-6 col-md-5 visible-sm"></div> <script>$('#div_search > *').clone().appendTo('#div_search2');</script> </div> </div> </header> <div id="main_content"> весь файл header.php (путь: catalog\controller\common\header.php) : <?php class ControllerCommonHeader extends Controller { public function index() { // Analytics $this->load->model('extension/extension'); $data['analytics'] = array(); $analytics = $this->model_extension_extension->getExtensions('analytics'); foreach ($analytics as $analytic) { if ($this->config->get($analytic['code'] . '_status')) { $data['analytics'][] = $this->load->controller('extension/analytics/' . $analytic['code'], $this->config->get($analytic['code'] . '_status')); } } if (isset($this->request->server['HTTPS']) && (($this->request->server['HTTPS'] == 'on') || ($this->request->server['HTTPS'] == '1'))) { $server = $this->config->get('config_ssl'); } else { $server = $this->config->get('config_url'); } if (is_file(DIR_IMAGE . $this->config->get('config_icon'))) { $this->document->addLink($server . 'image/' . $this->config->get('config_icon'), 'icon'); } $data['title'] = $this->document->getTitle(); $data['base'] = $server; $data['description'] = $this->document->getDescription(); $data['keywords'] = $this->document->getKeywords(); $data['links'] = $this->document->getLinks(); $data['styles'] = $this->document->getStyles(); $data['scripts'] = $this->document->getScripts(); $data['lang'] = $this->language->get('code'); $data['direction'] = $this->language->get('direction'); $data['name'] = $this->config->get('config_name'); if (is_file(DIR_IMAGE . $this->config->get('config_logo'))) { $data['logo'] = $server . 'image/' . $this->config->get('config_logo'); } else { $data['logo'] = ''; } $this->load->language('common/header'); $data['og_url'] = (isset($this->request->server['HTTPS']) && (($this->request->server['HTTPS'] == 'on') || ($this->request->server['HTTPS'] == '1')) ? HTTPS_SERVER : HTTP_SERVER) . substr($this->request->server['REQUEST_URI'], 1, (strlen($this->request->server['REQUEST_URI'])-1)); $data['og_image'] = $this->document->getOgImage(); $data['text_home'] = $this->language->get('text_home'); // Wishlist if ($this->customer->isLogged()) { $this->load->model('account/wishlist'); $data['text_wishlist'] = sprintf($this->language->get('text_wishlist'), $this->model_account_wishlist->getTotalWishlist()); } else { $data['text_wishlist'] = sprintf($this->language->get('text_wishlist'), (isset($this->session->data['wishlist']) ? count($this->session->data['wishlist']) : 0)); } $data['text_shopping_cart'] = $this->language->get('text_shopping_cart'); $data['text_logged'] = sprintf($this->language->get('text_logged'), $this->url->link('account/account', '', true), $this->customer->getFirstName(), $this->url->link('account/logout', '', true)); $data['text_account'] = $this->language->get('text_account'); $data['text_register'] = $this->language->get('text_register'); $data['text_login'] = $this->language->get('text_login'); $data['text_order'] = $this->language->get('text_order'); $data['text_transaction'] = $this->language->get('text_transaction'); $data['text_download'] = $this->language->get('text_download'); $data['text_logout'] = $this->language->get('text_logout'); $data['text_checkout'] = $this->language->get('text_checkout'); $data['text_page'] = $this->language->get('text_page'); $data['text_category'] = $this->language->get('text_category'); $data['text_all'] = $this->language->get('text_all'); $data['home'] = $this->url->link('common/home'); $data['wishlist'] = $this->url->link('account/wishlist', '', true); $data['logged'] = $this->customer->isLogged(); $data['account'] = $this->url->link('account/account', '', true); $data['register'] = $this->url->link('account/register', '', true); $data['login'] = $this->url->link('account/login', '', true); $data['order'] = $this->url->link('account/order', '', true); $data['transaction'] = $this->url->link('account/transaction', '', true); $data['download'] = $this->url->link('account/download', '', true); $data['logout'] = $this->url->link('account/logout', '', true); $data['shopping_cart'] = $this->url->link('checkout/cart'); $data['checkout'] = $this->url->link('checkout/checkout', '', true); $data['contact'] = $this->url->link('information/contact'); $data['telephone'] = $this->config->get('config_telephone'); // Menu $this->load->model('catalog/category'); $this->load->model('catalog/product'); $this->load->model('tool/image'); $data['categories'] = array(); $categories = $this->model_catalog_category->getCategories(0); foreach ($categories as $category) { if ($category['top']) { // Level 2 $children_data = array(); $children = $this->model_catalog_category->getCategories($category['category_id']); foreach ($children as $child) { $filter_data = array( 'filter_category_id' => $child['category_id'], 'filter_sub_category' => true ); if ($child['image']) { $cat_image = $this->model_tool_image->resize($child['image'], $this->config->get($this->config->get('config_theme') . '_image_category_width'), $this->config->get($this->config->get('config_theme') . '_image_category_height')); } else { $cat_image = ''; } $children_data[] = array( 'name' => $child['name'] . ($this->config->get('config_product_count') ? ' (' . $this->model_catalog_product->getTotalProducts($filter_data) . ')' : ''), 'thumb' => $cat_image, 'href' => $this->url->link('product/category', 'path=' . $category['category_id'] . '_' . $child['category_id']) ); } // Level 1 $data['categories'][] = array( 'name' => $category['name'], 'children' => $children_data, 'column' => $category['column'] ? $category['column'] : 1, 'href' => $this->url->link('product/category', 'path=' . $category['category_id']) ); } } $data['language'] = $this->load->controller('common/language'); $data['currency'] = $this->load->controller('common/currency'); $data['search'] = $this->load->controller('common/search'); $data['cart'] = $this->load->controller('common/cart'); // For page specific css if (isset($this->request->get['route'])) { if (isset($this->request->get['product_id'])) { $class = '-' . $this->request->get['product_id']; } elseif (isset($this->request->get['path'])) { $class = '-' . $this->request->get['path']; } elseif (isset($this->request->get['manufacturer_id'])) { $class = '-' . $this->request->get['manufacturer_id']; } elseif (isset($this->request->get['information_id'])) { $class = '-' . $this->request->get['information_id']; } else { $class = ''; } $data['class'] = str_replace('/', '-', $this->request->get['route']) . $class; } else { $data['class'] = 'common-home'; } return $this->load->view('common/header', $data); } } файл category.tpl (путь: catalog\view\theme\unishop\template\product\category.tpl) темы прописано так: <?php echo $header; ?> <div class="container"> <ul class="breadcrumb <?php if (in_array('product/category', $menu_schema)) { ?>col-md-offset-4 col-lg-offset-3<?php } ?>"> <?php foreach ($breadcrumbs as $i=> $breadcrumb) { ?> <?php if($i+1<count($breadcrumbs)) { ?> <li><a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a></li> <?php } else { ?> <li><?php echo $breadcrumb['text']; ?></li><?php } ?> <?php } ?> </ul> <div class="row"><?php echo $column_left; ?> <?php if ($column_left && $column_right) { ?> <?php $class = 'col-sm-4 col-md-4 col-lg-6'; ?> <?php } elseif ($column_left || $column_right) { ?> <?php $class = 'col-sm-8 col-md-8 col-lg-9'; ?> <?php } else { ?> <?php $class = 'col-sm-12'; ?> <?php } ?> <?php if (in_array('product/category', $menu_schema) && !$column_left && $column_right) { $class = 'col-sm-8 col-md-8 col-lg-6 col-md-offset-4 col-lg-offset-3'; } ?> <?php if (in_array('product/category', $menu_schema) && !$column_left && !$column_right) { $class = 'col-sm-8 col-md-8 col-lg-9 col-md-offset-4 col-lg-offset-3'; } ?> <div id="content" class="<?php echo $class; ?>"><?php echo $content_top; ?> <h1 class="heading"><span><?php echo $heading_title; ?></span></h1> <?php if (($thumb || $description) && !$is_filter_page) { ?> <div class="row"> <div class="category-info"> <div class="col-xs-12"> <hr /> <?php if ($thumb) { ?><div class="image"><img src="<?php echo $thumb; ?>" alt="<?php echo $heading_title; ?>" title="<?php echo $heading_title; ?>" class="img-thumbnail" /></div><?php } ?> <?php if ($description) { ?><div class="description"><?php echo $description; ?></div><?php } ?> <hr /> </div> <?php if($cat_desc_pos == 'bottom') { ?><script>$(document).ready(function() {$('.cat_desc').append($('.category-info'));});</script><?php } ?> </div> </div> <?php } ?> <?php if ($categories) { ?> <div class="category_list row"> <?php foreach ($categories as $category) { ?> <div class="category <?php echo $subcategory_column; ?>"> <a href="<?php echo $category['href']; ?>"> <?php if($category['thumb']) { ?><img src="<?php echo $category['thumb']; ?>" alt="" title="" class="img-responsive" /><?php } ?> <p><?php echo $category['name']; ?></p> </a> </div> <?php } ?> </div> <?php } ?> <?php if ($products) { ?> <?php if(!$compare_btn_disabled) { ?><p style="margin:0"><a href="<?php echo $compare; ?>" id="compare-total"><?php echo $text_compare; ?></a></p><?php } ?> <div class="row"> <div class="col-xs-12"><hr /></div> <div class="col-xs-12 col-sm-4 col-md-3 col-lg-2 hidden-xs"> <div class="btn-group"> <?php echo $show_grid_button ? '<button type="button" id="grid-view" class="btn btn-default" data-toggle="tooltip" title="'.$button_grid.'"><i class="fa fa-th"></i></button>' : ''; ?> <?php echo $show_list_button ? '<button type="button" id="list-view" class="btn btn-default" data-toggle="tooltip" title="'.$button_list.'"><i class="fa fa-th-list"></i></button>' : ''; ?> <?php echo $show_compact_button ? '<button type="button" id="compact-view" class="btn btn-default" data-toggle="tooltip" title="'.$lang['button_compact'].'" onclick="compact_view()"><i class="fa fa-align-justify"></i></button>' : ''; ?> </div> </div> <div class="col-xs-6 col-sm-5 col-md-4 col-lg-4 col-md-offset-2 col-lg-offset-3 text-right"> <div class="input-group"> <span class="input-group-addon"><i class="fa fa-sort"></i><span class="hidden-xs hidden-sm hidden-md"><?php echo $text_sort; ?></span></span> <select id="input-sort" class="form-control" onchange="location = this.value;"> <?php foreach ($sorts as $sorts) { ?> <?php if ($sorts['value'] == $sort . '-' . $order) { ?> <option value="<?php echo $sorts['href']; ?>" selected="selected"><?php echo $sorts['text']; ?></option> <?php } else { ?> <option value="<?php echo $sorts['href']; ?>"><?php echo $sorts['text']; ?></option> <?php } ?> <?php } ?> </select> </div> </div> <div class="col-xs-6 col-sm-3 col-md-3 col-lg-3 text-right"> <div class="input-group"> <span class="input-group-addon"><i class="fa fa-eye"></i><span class="hidden-xs hidden-sm hidden-md"><?php echo $text_limit; ?></span></span> <select id="input-limit" class="form-control" onchange="location = this.value;"> <?php foreach ($limits as $limits) { ?> <?php if ($limits['value'] == $limit) { ?> <option value="<?php echo $limits['href']; ?>" selected="selected"><?php echo $limits['text']; ?></option> <?php } else { ?> <option value="<?php echo $limits['href']; ?>"><?php echo $limits['text']; ?></option> <?php } ?> <?php } ?> </select> </div> </div> <div class="col-xs-12"><hr /></div> </div> <div class="products-block row"> <?php if ($column_left && $column_right) { ?> <?php $class = 'col-lg-6 col-md-12 col-sm-12 col-xs-12'; ?> <?php } elseif ($column_left || $column_right) { ?> <?php $class = 'col-lg-4 col-md-6 col-sm-6 col-xs-12'; ?> <?php } else { ?> <?php $class = 'col-lg-3 col-md-3 col-sm-6 col-xs-12'; ?> <?php } ?> <?php foreach ($products as $product) { ?> <div class="product-layout product-grid <?php echo $class; ?>"> <div class="product-thumb transition"> <div class="image"> <?php foreach($product['stickers'] as $sticker) { ?> <div class="product_sticker <?php echo $sticker['name']; ?>"><?php echo $sticker['text']; ?> <?php echo $sticker['value']; ?> <?php echo $sticker['text_after']; ?></div> <?php } ?> <a href="<?php echo $product['href']; ?>"> <img src="<?php echo $product['thumb']; ?>" <?php if ($product['quantity'] < 1 && $show_stock_status) { ?>data-status="<?php echo $product['stock_status']; ?>" data-status-id="<?php echo $product['stock_status_id']; ?>"<?php } ?> <?php if($product['additional_image']) { ?>data-additional="<?php echo $product['additional_image'];?>"<?php } ?> alt="<?php echo $product['name']; ?>" title="<?php echo $product['name']; ?>" class="img-responsive" /> </a> </div> <div class="caption"> <a href="<?php echo $product['href']; ?>"><?php echo $product['name']; ?></a> <?php if ($show_description || ($show_description_alt && !$product['attribute_groups'])) { ?> <p class="description"><?php echo $product['description']; ?></p> <?php } ?> <?php if ($show_attr) { ?> <div class="attribute <?php if ($show_description_alt && !$product['attribute_groups']) { ?>attribute_alt<?php } ?>"> <?php foreach ($product['attribute_groups'] as $attribute_group) { ?> <?php foreach ($attribute_group['attribute'] as $attribute) { ?> <?php if ($show_attr_name) { ?><span class="attr_name"><?php echo $attribute['name']; ?>:</span><?php } ?> <span class="attr_value"><?php echo $attribute['text']; ?></span> <?php } ?> <?php } ?> </div> <?php } ?> <div id="option_<?php echo $product['product_id']; ?>" class="option"> <?php if ($product['options']) { ?> <?php foreach ($product['options'] as $option) { ?> <?php if ($option['type'] == 'checkbox' || $option['type'] == 'select' || $option['type'] == 'radio' || $option['type'] == 'image') { ?> <div id="input-option<?php echo $option['product_option_id']; ?>"> <?php if ($option['required']) { ?>*<?php } ?> <label><?php echo $option['name']; ?>:</label><br /> <?php if ($option['type'] == 'select') { ?> <select name="option[<?php echo $option['product_option_id']; ?>]" class="form-control"> <option value=""><?php echo $text_select; ?></option> <?php foreach ($option['product_option_value'] as $option_value) { ?> <option value="<?php echo $option_value['product_option_value_id']; ?>" data-name="<?php echo $option['name'].': '.$option_value['name']; ?>"><?php echo $option_value['name']; ?><?php if ($option_value['price']) { ?>(<?php echo $option_value['price_prefix']; ?><?php echo $option_value['price']; ?>)<?php } ?></option> <?php } ?> </select> <?php } ?> <?php if ($option['type'] == 'checkbox' || $option['type'] == 'radio' || $option['type'] == 'image') { ?> <?php foreach ($option['product_option_value'] as $option_value) { ?> <label class="input"> <?php if ($option['type'] == 'checkbox') { ?> <input type="checkbox" name="option[<?php echo $option['product_option_id']; ?>][]" value="<?php echo $option_value['product_option_value_id']; ?>" id="option-value-<?php echo $option_value['product_option_value_id']; ?>" data-name="<?php echo $option['name'].': '.$option_value['name']; ?>" /> <?php } ?> <?php if ($option['type'] == 'radio' || $option['type'] == 'image') { ?> <input type="radio" name="option[<?php echo $option['product_option_id']; ?>]" value="<?php echo $option_value['product_option_value_id']; ?>" id="option-value-<?php echo $option_value['product_option_value_id']; ?>" data-name="<?php echo $option['name'].': '.$option_value['name']; ?>" /> <?php if($option_value['image']) { ?> <span class="img" title="<?php echo $option_value['name'] . ($option_value['price'] ? ' ' . $option_value['price_prefix'] . $option_value['price'] : ''); ?>" data-toggle="tooltip" data-thumb="<?php echo $option_value['small']; ?>"> <img src="<?php echo $option_value['image']; ?>" data-toggle="tooltip" alt="<?php echo $option_value['name'] . ($option_value['price'] ? ' ' . $option_value['price_prefix'] . $option_value['price'] : ''); ?>" class="img-thumbnail" /> </span> <?php } ?> <?php } ?> <span><?php echo $option_value['name']; ?><?php if ($option_value['price']) { ?><span>(<?php echo $option_value['price_prefix']; ?><?php echo $option_value['price']; ?>)</span><?php } ?></span> </label> <?php } ?> <?php } ?> </div> <?php } ?> <?php } ?> <?php } ?> </div> <?php if ($product['rating'] >= 0 && $show_rating) { ?> <div class="rating"> <?php for ($i = 1; $i <= 5; $i++) { ?> <?php if ($product['rating'] < $i) { ?> <span class="fa fa-stack"><i class="far fa-star fa-stack-2x"></i></span> <?php } else { ?> <span class="fa fa-stack"><i class="fa fa-star fa-stack-2x"></i></span> <?php } ?> <?php } ?> <?php if ($show_rating_count) { ?><sup><a onclick="location='<?php echo $product['href']; ?>#tab-review'"><?php echo $product['num_reviews']; ?></a></sup><?php } ?> </div> <?php } ?> <?php if ($product['price']) { ?> <p class="price"> <?php if (!$product['special']) { ?> <?php echo $product['price']; ?> <?php } else { ?> <span class="price-old"><?php echo $product['price']; ?></span> <span class="price-new"><?php echo $product['special']; ?></span> <?php } ?> <?php if ($product['tax']) { ?> <span class="price-tax"><?php echo $text_tax; ?> <?php echo $product['tax']; ?></span> <?php } ?> </p> <?php } ?> </div> <div class="cart"> <button type="button" class="add_to_cart button btn btn-default <?php echo $product['cart_btn_class']; ?> <?php echo $product['product_id']; ?>" data-toggle="tooltip" title="<?php echo $product['cart_btn_text']; ?>" onclick="cart.add(<?php echo $product['product_id']; ?>)"><i class="<?php echo $product['cart_btn_icon']; ?>"></i><span class="hidden-sm"><?php echo $product['cart_btn_text']; ?></span></button> <?php if ($show_quick_order && $show_quick_order_quantity || $show_quick_order && $product['quantity'] > 0) { ?> <button type="button" class="quick_order button btn btn-default" data-toggle="tooltip" title="<?php echo $quick_order_title; ?>" onclick="quick_order('<?php echo $product['product_id']; ?>');"><i class="<?php echo $quick_order_icon; ?>"></i><?php echo ($show_quick_order_text ? '<span class="hidden-sm">'.$quick_order_title.'</span>' : '') ?></button> <?php } ?> <?php if(!$wishlist_btn_disabled) { ?><button type="button" class="wishlist btn btn-default" data-toggle="tooltip" title="<?php echo $button_wishlist; ?>" onclick="wishlist.add('<?php echo $product['product_id']; ?>');"><i class="fa fa-heart"></i></button><?php } ?> <?php if(!$compare_btn_disabled) { ?><button type="button" class="compare btn btn-default" data-toggle="tooltip" title="<?php echo $button_compare; ?>" onclick="compare.add('<?php echo $product['product_id']; ?>');"><i class="fa fa-exchange-alt"></i></button><?php } ?> </div> </div> </div> <?php } ?> </div> <?php if (isset($uni_banner_in_category)) { ?> <script> var window_width = $(window).width(); <?php foreach($uni_banner_in_category as $banner) { ?> var banner = '<div class="uni-banner-in-category id-<?php echo $banner['banner_id']; ?>">'; <?php if($banner['image']) { ?> banner += '<img src="<?php echo $banner['image']; ?>" class="img-responsive" onclick="location=\'<?php echo $banner['href']; ?>\'" />'; <?php } else { ?> banner += '<div class="description"><?php echo $banner['description']; ?></div>'; banner += '<button class="btn btn-sm btn-primary" onclick="location=\'<?php echo $banner['href']; ?>\'"><?php echo $banner['button']; ?></button>'; <?php } ?> banner += '</div>'; var position = (window_width > 1600) ? <?php echo $banner['position2']; ?> : <?php echo $banner['position']; ?>; if(window_width > 992) { $('.products-block .product-layout:eq('+(position-1)+')').before(banner); } <?php } ?> </script> <?php } ?> <div class="pagination_wrap row"> <div class="col-sm-6 text-left"><?php echo $pagination; ?></div> <div class="col-sm-6 text-right"><?php echo $results; ?></div> </div> <?php } ?> <?php if (!$categories && !$products) { ?> <p><?php echo $text_empty; ?></p> <?php } ?> <div class="cat_desc row"></div> <?php if (isset($description_bottom)) { ?> <div class="row"> <div class="col-xs-12"><?php echo $description_bottom; ?></div> </div> <?php } ?> <?php echo $content_bottom; ?> </div> <?php echo $column_right; ?> </div> </div> <script type="application/ld+json"> { "@context": "http://schema.org", "@type": "BreadcrumbList", "itemListElement": [ <?php foreach($breadcrumbs as $i => $breadcrumb) { ?> { "@type": "ListItem", "position": <?php echo $i++; ?>, "item" : { "@id": "<?php echo $breadcrumb['href']; ?>", "name": "<?php echo $i == 1 ? $shop_name : $breadcrumb['text']; ?>" } }<?php echo $i < count($breadcrumbs) ? ', ' : ''; ?> <?php } ?> ] } </script> <?php echo $footer; ?> файл category.php (путь: catalog\controller\product\category.php) такой: <?php class ControllerProductCategory extends Controller { public function index() { $this->load->language('product/category'); $this->load->model('catalog/category'); $this->load->model('catalog/product'); $this->load->model('tool/image'); if (isset($this->request->get['filter'])) { $filter = $this->request->get['filter']; } else { $filter = ''; } if (isset($this->request->get['sort'])) { $sort = $this->request->get['sort']; } else { $sort = 'p.sort_order'; } if (isset($this->request->get['order'])) { $order = $this->request->get['order']; } else { $order = 'ASC'; } if (isset($this->request->get['page'])) { $page = $this->request->get['page']; } else { $page = 1; } if (isset($this->request->get['limit'])) { $limit = (int)$this->request->get['limit']; } else { $limit = $this->config->get($this->config->get('config_theme') . '_product_limit'); } $data['breadcrumbs'] = array(); $data['breadcrumbs'][] = array( 'text' => $this->language->get('text_home'), 'href' => $this->url->link('common/home') ); if (isset($this->request->get['path'])) { $url = ''; if (isset($this->request->get['sort'])) { $url .= '&sort=' . $this->request->get['sort']; } if (isset($this->request->get['order'])) { $url .= '&order=' . $this->request->get['order']; } if (isset($this->request->get['limit'])) { $url .= '&limit=' . $this->request->get['limit']; } $path = ''; $parts = explode('_', (string)$this->request->get['path']); $category_id = (int)array_pop($parts); foreach ($parts as $path_id) { if (!$path) { $path = (int)$path_id; } else { $path .= '_' . (int)$path_id; } $category_info = $this->model_catalog_category->getCategory($path_id); if ($category_info) { $data['breadcrumbs'][] = array( 'text' => $category_info['name'], 'href' => $this->url->link('product/category', 'path=' . $path . $url) ); } } } else { $category_id = 0; } $category_info = $this->model_catalog_category->getCategory($category_id); if ($category_info) { if ($category_info['meta_title']) { $this->document->setTitle($category_info['meta_title']); } else { $this->document->setTitle($category_info['name']); } $this->document->setDescription($category_info['meta_description']); $this->document->setKeywords($category_info['meta_keyword']); if ($category_info['meta_h1']) { $data['heading_title'] = $category_info['meta_h1']; } else { $data['heading_title'] = $category_info['name']; } $data['text_refine'] = $this->language->get('text_refine'); $data['text_empty'] = $this->language->get('text_empty'); $data['text_quantity'] = $this->language->get('text_quantity'); $data['text_manufacturer'] = $this->language->get('text_manufacturer'); $data['text_model'] = $this->language->get('text_model'); $data['text_price'] = $this->language->get('text_price'); $data['text_tax'] = $this->language->get('text_tax'); $data['text_points'] = $this->language->get('text_points'); $data['text_compare'] = sprintf($this->language->get('text_compare'), (isset($this->session->data['compare']) ? count($this->session->data['compare']) : 0)); $data['text_sort'] = $this->language->get('text_sort'); $data['text_limit'] = $this->language->get('text_limit'); $data['button_cart'] = $this->language->get('button_cart'); $data['button_wishlist'] = $this->language->get('button_wishlist'); $data['button_compare'] = $this->language->get('button_compare'); $data['button_continue'] = $this->language->get('button_continue'); $data['button_list'] = $this->language->get('button_list'); $data['button_grid'] = $this->language->get('button_grid'); // Set the last category breadcrumb $data['breadcrumbs'][] = array( 'text' => $category_info['name'], 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path']) ); if ($category_info['image']) { $data['thumb'] = $this->model_tool_image->resize($category_info['image'], $this->config->get($this->config->get('config_theme') . '_image_category_width'), $this->config->get($this->config->get('config_theme') . '_image_category_height')); $this->document->setOgImage($data['thumb']); } else { $data['thumb'] = ''; } $data['description'] = html_entity_decode($category_info['description'], ENT_QUOTES, 'UTF-8'); $data['compare'] = $this->url->link('product/compare'); $url = ''; if (isset($this->request->get['filter'])) { $url .= '&filter=' . $this->request->get['filter']; } if (isset($this->request->get['sort'])) { $url .= '&sort=' . $this->request->get['sort']; } if (isset($this->request->get['order'])) { $url .= '&order=' . $this->request->get['order']; } if (isset($this->request->get['limit'])) { $url .= '&limit=' . $this->request->get['limit']; } $data['categories'] = array(); $results = $this->model_catalog_category->getCategories($category_id); foreach ($results as $result) { $filter_data = array( 'filter_category_id' => $result['category_id'], 'filter_sub_category' => true ); $data['categories'][] = array( 'name' => $result['name'] . ($this->config->get('config_product_count') ? ' (' . $this->model_catalog_product->getTotalProducts($filter_data) . ')' : ''), 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '_' . $result['category_id'] . $url) ); } $data['products'] = array(); $filter_data = array( 'filter_category_id' => $category_id, 'filter_filter' => $filter, 'sort' => $sort, 'order' => $order, 'start' => ($page - 1) * $limit, 'limit' => $limit ); $product_total = $this->model_catalog_product->getTotalProducts($filter_data); $results = $this->model_catalog_product->getProducts($filter_data); foreach ($results as $result) { if ($result['image']) { $image = $this->model_tool_image->resize($result['image'], $this->config->get($this->config->get('config_theme') . '_image_product_width'), $this->config->get($this->config->get('config_theme') . '_image_product_height')); } else { $image = $this->model_tool_image->resize('placeholder.png', $this->config->get($this->config->get('config_theme') . '_image_product_width'), $this->config->get($this->config->get('config_theme') . '_image_product_height')); } if ($this->customer->isLogged() || !$this->config->get('config_customer_price')) { $price = $this->currency->format($this->tax->calculate($result['price'], $result['tax_class_id'], $this->config->get('config_tax')), $this->session->data['currency']); } else { $price = false; } if ((float)$result['special']) { $special = $this->currency->format($this->tax->calculate($result['special'], $result['tax_class_id'], $this->config->get('config_tax')), $this->session->data['currency']); } else { $special = false; } if ($this->config->get('config_tax')) { $tax = $this->currency->format((float)$result['special'] ? $result['special'] : $result['price'], $this->session->data['currency']); } else { $tax = false; } if ($this->config->get('config_review_status')) { $rating = (int)$result['rating']; } else { $rating = false; } $data['products'][] = array( 'product_id' => $result['product_id'], 'thumb' => $image, 'name' => $result['name'], 'description' => utf8_substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get($this->config->get('config_theme') . '_product_description_length')) . '..', 'price' => $price, 'special' => $special, 'tax' => $tax, 'minimum' => ($result['minimum'] > 0) ? $result['minimum'] : 1, 'rating' => $rating, 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id'] . $url) ); } $url = ''; if (isset($this->request->get['filter'])) { $url .= '&filter=' . $this->request->get['filter']; } if (isset($this->request->get['limit'])) { $url .= '&limit=' . $this->request->get['limit']; } $data['sorts'] = array(); $data['sorts'][] = array( 'text' => $this->language->get('text_default'), 'value' => 'p.sort_order-ASC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=p.sort_order&order=ASC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_name_asc'), 'value' => 'pd.name-ASC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=pd.name&order=ASC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_name_desc'), 'value' => 'pd.name-DESC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=pd.name&order=DESC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_price_asc'), 'value' => 'p.price-ASC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=p.price&order=ASC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_price_desc'), 'value' => 'p.price-DESC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=p.price&order=DESC' . $url) ); if ($this->config->get('config_review_status')) { $data['sorts'][] = array( 'text' => $this->language->get('text_rating_desc'), 'value' => 'rating-DESC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=rating&order=DESC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_rating_asc'), 'value' => 'rating-ASC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=rating&order=ASC' . $url) ); } $data['sorts'][] = array( 'text' => $this->language->get('text_model_asc'), 'value' => 'p.model-ASC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=p.model&order=ASC' . $url) ); $data['sorts'][] = array( 'text' => $this->language->get('text_model_desc'), 'value' => 'p.model-DESC', 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . '&sort=p.model&order=DESC' . $url) ); $url = ''; if (isset($this->request->get['filter'])) { $url .= '&filter=' . $this->request->get['filter']; } if (isset($this->request->get['sort'])) { $url .= '&sort=' . $this->request->get['sort']; } if (isset($this->request->get['order'])) { $url .= '&order=' . $this->request->get['order']; } $data['limits'] = array(); $limits = array_unique(array($this->config->get($this->config->get('config_theme') . '_product_limit'), 25, 50, 75, 100)); sort($limits); foreach($limits as $value) { $data['limits'][] = array( 'text' => $value, 'value' => $value, 'href' => $this->url->link('product/category', 'path=' . $this->request->get['path'] . $url . '&limit=' . $value) ); } $url = ''; if (isset($this->request->get['filter'])) { $url .= '&filter=' . $this->request->get['filter']; } if (isset($this->request->get['sort'])) { $url .= '&sort=' . $this->request->get['sort']; } if (isset($this->request->get['order'])) { $url .= '&order=' . $this->request->get['order']; } if (isset($this->request->get['limit'])) { $url .= '&limit=' . $this->request->get['limit']; } $pagination = new Pagination(); $pagination->total = $product_total; $pagination->page = $page; $pagination->limit = $limit; $pagination->url = $this->url->link('product/category', 'path=' . $this->request->get['path'] . $url . '&page={page}'); $data['pagination'] = $pagination->render(); $data['results'] = sprintf($this->language->get('text_pagination'), ($product_total) ? (($page - 1) * $limit) + 1 : 0, ((($page - 1) * $limit) > ($product_total - $limit)) ? $product_total : ((($page - 1) * $limit) + $limit), $product_total, ceil($product_total / $limit)); if (!$this->config->get('config_canonical_method')) { // http://googlewebmastercentral.blogspot.com/2011/09/pagination-with-relnext-and-relprev.html if ($page == 1) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'], true), 'canonical'); } elseif ($page == 2) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'], true), 'prev'); } else { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'] . '&page=' . ($page - 1), true), 'prev'); } if ($limit && ceil($product_total / $limit) > $page) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'] . '&page=' . ($page + 1), true), 'next'); } } else { if (isset($this->request->server['HTTPS']) && (($this->request->server['HTTPS'] == 'on') || ($this->request->server['HTTPS'] == '1'))) { $server = $this->config->get('config_ssl'); } else { $server = $this->config->get('config_url'); }; $request_url = rtrim($server, '/') . $this->request->server['REQUEST_URI']; $canonical_url = $this->url->link('product/category', 'path=' . $category_info['category_id'], true); if (($request_url != $canonical_url) || $this->config->get('config_canonical_self')) { $this->document->addLink($canonical_url, 'canonical'); } if ($this->config->get('config_add_prevnext')) { if ($page == 2) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'], true), 'prev'); } elseif ($page > 2) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'] . '&page=' . ($page - 1), true), 'prev'); } if ($limit && ceil($product_total / $limit) > $page) { $this->document->addLink($this->url->link('product/category', 'path=' . $category_info['category_id'] . '&page=' . ($page + 1), true), 'next'); } } } $data['sort'] = $sort; $data['order'] = $order; $data['limit'] = $limit; $data['continue'] = $this->url->link('common/home'); $data['column_left'] = $this->load->controller('common/column_left'); $data['column_right'] = $this->load->controller('common/column_right'); $data['content_top'] = $this->load->controller('common/content_top'); $data['content_bottom'] = $this->load->controller('common/content_bottom'); $data['footer'] = $this->load->controller('common/footer'); $data['header'] = $this->load->controller('common/header'); $this->response->setOutput($this->load->view('product/category', $data)); } else { $url = ''; if (isset($this->request->get['path'])) { $url .= '&path=' . $this->request->get['path']; } if (isset($this->request->get['filter'])) { $url .= '&filter=' . $this->request->get['filter']; } if (isset($this->request->get['sort'])) { $url .= '&sort=' . $this->request->get['sort']; } if (isset($this->request->get['order'])) { $url .= '&order=' . $this->request->get['order']; } if (isset($this->request->get['page'])) { $url .= '&page=' . $this->request->get['page']; } if (isset($this->request->get['limit'])) { $url .= '&limit=' . $this->request->get['limit']; } $data['breadcrumbs'][] = array( 'text' => $this->language->get('text_error'), 'href' => $this->url->link('product/category', $url) ); $this->document->setTitle($this->language->get('text_error')); $data['heading_title'] = $this->language->get('text_error'); $data['text_error'] = $this->language->get('text_error'); $data['button_continue'] = $this->language->get('button_continue'); $data['continue'] = $this->url->link('common/home'); $this->response->addHeader($this->request->server['SERVER_PROTOCOL'] . ' 404 Not Found'); $data['column_left'] = $this->load->controller('common/column_left'); $data['column_right'] = $this->load->controller('common/column_right'); $data['content_top'] = $this->load->controller('common/content_top'); $data['content_bottom'] = $this->load->controller('common/content_bottom'); $data['footer'] = $this->load->controller('common/footer'); $data['header'] = $this->load->controller('common/header'); $this->response->setOutput($this->load->view('error/not_found', $data)); } } } Кто сталкивался с этой проблемой и каким образом можно решить? так как проверил все форуми и ютуб и ничего, повсюду одинакова инструкция а она не работает для unishop
-
Автоматическая обработка прайс-листов.
file залишив відгук до VladimirIvanov usergio в Обмен данными
- 13 коментарів
-
- 1
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
У меня например тоже в каждой категории подкатегории одинаковы а еще подкатегории могут быр разные а могут и одинаковы! Я добавил все работает категории добавились!
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
Как то добавил) но создал категории и вкладка Категории и наценки назначил потому что вроде все правильно создал категории и в прайсе но все равно модуль не понимал где какая категория. товар так и не создался через картинку но урл на картинку правильний. Спасибо) Еще вопрос если есть другой язык английский то я переключаюсь в админке на него і добавляю тот же прайс но только Производители уже на английском? И при єтом мне нужно Действие: только обновлять правильно?
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
Пробовал также разные вариации артикул опредиляет товар, опцию также разные вариации с выбором Действие: не помогло никак вроде все ок такое ж сообщение как и при добавлении категорий но ни одного Производителя по факту не добавлено!
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
По этому возможно нереально добавить просто производителей через этот модуль. Возможно столбец с производитель только для указания товара настройка при добалении товара?
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
Но я отметил их но они пустие так как по факту их не к чему добавлять. Когда добавляю Категории таким способом ариткул и цена колонки тоже пустие! Все работает для категорий а вот здесь нет(
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
В файле есть только производители нужно их добавить (пока делаю это вручную) Все поля звездочками отметил и указал 1 поле для Производителя только оно и заполено! Не хочет добавлять производителей! Пофторюсь если не четко сформулировал вопрос: Нужно добавить только производителей а товари сам менеджер добавит! Пробовал разные варианти с Действие: ничего не помогло. Категории легко добавить а вот производителей нет к сожалению отметил все поля с звездочкей (они конечно пустие так как нужно добавить только производителей)! Автору написал в ЛС но его ответ тоже не дал результата написал еще раз более подробно с скринами!
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
Пробовал без указания Категории не хочет создать. Тут вроде создает но не добавляет!
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
А что нужно вибрать? потому что я вроде поставил а оно никаких результатов. Где Действие: что нужно вибрать я вибираю Только добавлять! Вот скрин моих настроек:
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)
-
Подскажите пожалуйста кто сталкивался. Как можно загрузить производителей через АОП с цсв файла?
- 49 459 відповідей
-
- поставщики импорт
- наполнение им
- (і ще %d)