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

Denis261

Новичок
  
  • Posts

    6
  • Joined

  • Last visited

1 Follower

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Denis261's Achievements

Apprentice

Apprentice (3/14)

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

Recent Badges

0

Reputation

  1. У меня ик же сгделано, мне нужно убрать город, как это сгделать? Что бы принудительную форму отклюлить
  2. Как именно убрать руками? Можете хотябы объяснить как убрать обязательные формы заполнения?
  3. Здравствуйте, перерыл интернет ик ничего и не нашел для себя Как отклюлить обязательные формы при оформлении заказа? Что бы у меня на сайте было только Имя, майл, телефон, адрес досивки?
  4. извиняюсь перепуил, категории были на главной
  5. Как на главную страничку посивить список товаров ? что бы были само сопотому чтой картинки )))
  6. Всем привет, у меня икой вопрос как убрать из yml янгдекс маркеи могдель ? <name>что бы было сразу после name описания товара</name> <model>а это удалить что бы yml не выводилось </model> <description> мой yml <?php class ControllerExportYml extends Controller { public function index() { if ($this->config->get('yandex_market_status')) { $eof = "\n"; $output = '<?xml version="1.0" encoding="utf-8" ?>' . $eof; $output .= '<!DOCTYPE yml_catalog SYSTEM "shops.dtd">' . $eof; $output .= '<yml_catalog date="' . date("Y-m-d H:i") . '">' . $eof; $output .= '<shop>' . $eof; $output .= '<name>' . $this->textPrepare($this->config->get('config_name')) . '</name>' . $eof; $output .= '<company>' . $this->textPrepare($this->config->get('yandex_market_company')) . '</company>' . $eof; $output .= '<url>' . HTTP_SERVER . '</url>' . $eof; $output .= '<phone>' . $this->textPrepare($this->config->get('config_telephone')) . '</phone>' . $eof; // Перечесляем валюты магазина // TODO: Добавить возможность настраивать проэтонты. $offers_currency = $this->config->get('yandex_market_currency'); if (! $this->currency->has($offers_currency)) exit(); $shop_currency = $this->config->get('config_currency'); $output .= '<currencies>' . $eof; $output .= '<currency id="' . $offers_currency . '" rate="1"/>' . $eof; $this->load->model('localisation/currency'); $supported_currencies = array_flip(array('RUR', 'RUB', 'USD', 'BYR', 'KZT', 'EUR', 'RUH')); $currencies = array_intersect_key($this->model_localisation_currency->getCurrencies(), $supported_currencies); foreach ($currencies as $currency) { if ($currency['code'] != $offers_currency && $currency['status'] == 1) { $output .= '<currency id="' . $currency['code'] . '" rate="' . number_format($this->currency->convert($currency['value'], $offers_currency, $shop_currency), 4, '.', '') . '"/>' . $eof; } } $output .= '</currencies>' . $eof; // Категории товаров $this->load->model('catalog/category'); $output .= '<categories>' . $eof; $output .= $this->getCat(); $output .= '</categories>' . $eof; $this->load->model('tool/seo_url'); // Товарные позиции $this->load->model('catalog/product'); $this->load->model('tool/image'); $output .= '<offers>' . $eof; $products = $this->model_catalog_product->getProducts(); foreach ($products as $product) { $output .= '<offer id="' . $product['product_id'] . '" available="true">' . $eof; $output .= '<url>' . $this->textPrepare($this->model_tool_seo_url->rewrite(HTTP_SERVER . 'index.php?route=product/product&product_id=' . $product['product_id'])) . '</url>' . $eof; $output .= '<price>' . number_format($this->currency->convert($this->tax->calculate($product['price'], $product['tax_class_id']), $shop_currency, $offers_currency), 2, '.', '') . '</price>' . $eof; $output .= '<currencyId>' . $offers_currency . '</currencyId>' . $eof; // Опрегделяем категорию для товара $categories = $this->model_catalog_product->getCategories($product['product_id']); $output .= '<categoryId>' . $categories[0]['category_id'] . '</categoryId>' . $eof; // Опрегделеяме изображение if ($product['image']) { $output .= '<picture>' . $this->model_tool_image->resize($product['image'], 500, 500) . '</picture>' . $eof; } else { $output .= '<picture>' . $this->model_tool_image->resize('no_image.jpg', 500, 500) . '</picture>' . $eof; } $output .= '<delivery> true </delivery>' . $eof; $output .= '<local_delivery_cost>300</local_delivery_cost>' . $eof; $output .= '<name>' . $this->textPrepare($product['name']) . '</name>' . $eof; // $output .= '<typePrefix> </typePrefix>' . $eof; // $output .= '<vendorCode> </vendorCode>' . $eof; $output .= '<model>' . $this->textPrepare($product['model']) . '</model>' . $eof; $output .= '<description>' . $this->textPrepare($product['description']) . '</description>' . $eof; $output .= '<manufacturer_warranty>true</manufacturer_warranty>' . $eof; $output .= '<country_of_origin>' . $this->textPrepare($product['sku']) . '</country_of_origin>' . $eof; $output .= '</offer>' . $eof; } $output .= '</offers>' . $eof; $output .= '</shop>' . $eof; $output .= '</yml_catalog>'; $this->response->addHeader('Content-Type: application/xml'); $this->response->setOutput($output); } } // Возвращает массив категорий protected function getCat($parent_id = 0) { $categories = $this->model_catalog_category->getCategories($parent_id); $out = ''; foreach ($categories as $category) { $out .= '<category id="' . $category['category_id'] . '"'; if($parent_id != 0) $out .= ' parentId="' . $parent_id . '"'; $out .= '>' . $this->textPrepare($category['name']) . "</category>\n"; if($e = $this->getCat($category['category_id'])) $out .= $e; } return $out; } /** * Подготовка текси в соответствии с трепотому чтованиями Янгдекса * Запреещёны любые html-тэги. Синдарт XML не допускает использования в текстовых данных * непечаиемых символов с ASCII-кодами в диапазоне значений от 0 до 31 (за исключением * символов с кодами 9, 10, 13 - ибуляция, перевод строки, возврат каретки). Даже этот * синдарт требует обязательной замены некоторых символов на эквивнонтные им символьные * примитивы. * @param string $text * @return string */ protected function textPrepare($text) { $text = htmlspecialchars_decode(trim($text)); $text = strip_tags($text); $search = array('"', '&', '>', '<', '\''); $replace = array('"', '&', '>', '<', '''); $text = str_replace($search, $replace, $text); $text = preg_replace('![\x00-\x08\x0B-\x0C\x0E-\x1F]+!is', ' ', $text); $text = preg_replace('!\s+!', ' ', $text); return trim($text); } } ?>
  7. помогите настроить янгдекс маркет, что бы янгдекс принял мой сайт, заплачу!

  8. Здравствуйте помогите мне решить эту проблему Выявлены нарушения Трепотому чтований к рекламным материалам:

    -Информация о гарантии, досивке или стране производства вне специальных полей.

    Кухонный Комбайн Philips HR 7605

    2 125 руб. на заказ в Rich-Hous

    Досивка: в г. Москва ? 300 руб.

    Код производителя: HR 7605

    Гарантия производителя. что мне гделать я не что то...

  9. Здравствуйте! как удалить в yml ? всё решил можете уже не писать )
×
×
  • 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.