User Guide This guide is available at Github Wiki: https://github.com/vovayatsyuk/magento2- alsoviewed/wiki Also Viewed Products - is a product suggestion module, powered by your visitors activity. Moreover, it can not just recommend products alternatives for currently viewed product, but it can build suggestions on your recent activities too: Recently viewed products Recently compared products Product from shopping cart How it works? Every time the client is looking at some product, module update relations between this and other recently viewed products. Day after day relations count are grows and they become more accurate. Contents 1. Configuration Product Page Tabs Integration Log Settings 2. Backend Interfaces Log Relations grid Relation page 3. Widget Insert widget into product page sidebar Insert widget into homepage
Configuration Module configuration is located at Stores > Configuration > Catalog > Also Viewed Products page. Product Page Tabs Integration This section allows you to enable and configure module output in standard Magento tabs. If your theme uses standard tabs - go ahead and use this section. Otherwise - follow your theme manual on how to add custom widget to theme tabs. In case if your theme does not have tabs, you can use widget to add Also Viewed Products to the product page.
Option Show block at Product Page tabs Tab Title Block Title Offer Recommendations for Products Count Listing mode Block css classes Description Enable/Disable block in product page tabs Tab title string. Use as short value as possible Title above product list inside tab You can add additional recommendation sources, to recommend product for Recently Viewed Products, Shopping Cart Items or other Set the value, that will match your theme preferences You can choose between Grid and List modes You can add/remove additional classes to match your theme requirements
Log Settings This section allows you to tune up module log behavior. You can modify Crawlers regex string to match specific crawlers or add specific IP-addresses to exclude your developers and support ip-addresses. Option Ignore crawlers Crawlers user agent regex Ignore specific ip addresses Ip addresses (comma separated) Description Set Yes to ignore some crawlers Add additional annoying crawler names Set Yes to ignore some addresses Add ip-addresses that should not be used to create product relations
Backend Interfaces Extension provides following backend interfaces under Backend Products menu item:
Log Log shows you recently created/updated products relations, that are not processed yet. The main purposes of this grid are: Check if the module is working well Run Process Log manually if you have troubles with cron setup
Relations grid Relations grid - is a list of all relations with their additional info: Weight Position Status Last Update Time Please note that the module creates independent bi-directional relations between products. This allows you to customize relation status separately per each of the product in a pair. (Eg. you can edit A to B and B to A relations separately). Grid filters allows you to find specific relation and edit it at the relation page.
Relation page Relation page provides an ability to manage relation status, weight and position. Additionally you have an ability to synchronize the same values for the inversed relation. Weight - is a popularity of particlular relation. The higher the weight of relation - the higher its reliability. Position - is used for manual relations sort order, without manipulation with weight attribute. Inversed Relation - is a mirrored relation (Eg. A to B and B to A ). In most cases you d like to have the same values for both relations.
Widget Also Viewed Products module provides a widget that could be used in multiple scenarios: 1. Show suggestions for currenlty viewed product 2. Show suggestions for recently viewed products 3. Show suggestions for recently compared products 4. Show suggestions for products in shopping cart 5. Show suggestions for any combinations of previously mentioned products Insert widget into product page sidebar This tutorial can be used to add widget to any other page or container. You can choose the page and container you need, at the bottom of Storefront properties tab. 1. Navigate to Content > Widgets page and press Add Widget button. 2. Select Also Viewed Products widget, your theme and press Continue :
3. Fill form values as shown on the screenshots below: Storefront properies tab:
Layout updates: Please keep in mind that you should select a "Container" that is actually visible on the selected page. For example, if your theme uses 1-column layout, and you select "Sidebar" as a container - you will not see the widget on the frontend. In order to see the widget, in this case, you should change the layout of this page to 3 or 2-columns using standard Magento functionality.
Widget options tab (Choose listing mode between list and grid ):
4. Save widget, clear cache and navigate to your store frontend:
Insert widget into homepage This tutorial can be used to add widget to any other cms page or block. 1. Navigate to Content > Pages (Or Content > Blocks, if you are using Luma theme) and open Homepage (Or Block) to edit. 2. Press Insert Widget button. 3. Select Also Viewed Widget and fill form values as shown below: Title value is not used. See next point screenshot for explanation.
4. Add additional markup: 5. Save page, clear cache and navigate to frontend: