Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
viewed_names_list.phtml
Go to the documentation of this file.
1 <?php
7 // @codingStandardsIgnoreFile
8 
9 ?>
10 <?php
14 ?>
15 <?php if (($_products = $block->getRecentlyViewedProducts()) && $_products->getSize()): ?>
16 <div class="block widget block-viewed-products-names">
17  <div class="block-title">
18  <strong><?= /* @escapeNotVerified */ __('Recently Viewed') ?></strong>
19  </div>
20  <div class="block-content">
21  <?php $suffix = $block->getNameInLayout(); ?>
22  <ol id="widget-viewed-<?= /* @escapeNotVerified */ $suffix ?>" class="product-items product-items-names">
23  <?php foreach ($_products as $_product): ?>
24  <li class="product-item">
25  <strong class="product-item-name">
26  <a href="<?= /* @escapeNotVerified */ $_product->getProductUrl() ?>" class="product-item-link">
27  <?= /* @escapeNotVerified */ $this->helper('Magento\Catalog\Helper\Output')->productAttribute($_product, $_product->getName(), 'name') ?>
28  </a>
29  </strong>
30  </li>
31  <?php endforeach; ?>
32  </ol>
33  </div>
34 </div>
35 <?php endif; ?>
$suffix
Definition: name.phtml:27
__()
Definition: __.php:13
foreach( $_products as $_product)() ?>" class endforeach
$_product
Definition: summary.phtml:12
$block
Definition: block.php:8