Recently Viewed


This plugin adds functionality to the existing Element Query fluent interface allowing you to filter and order elements by whether they have been recently viewed by the user.

Just like 'recently viewed products' on Amazon.

'Views' can be automatically tracked based on URLs visited by the user and displaying is as easy as:

{% set recentBlogPosts = craft.entries.section('blogPosts').recentlyViewed().orderByDateViewed().limit(3).all() %}

The plugin will work with any element type, including Commerce products and any custom elements from other plugins.

If you don't want to auto-track views, or you'd like to track views on elements which can't be natively linked to a specific URL (such as Assets or tags) you can manually track views like so:

{% do craft.recentlyViewed.track(element) %}

Where element can be anything that implements craft\base\ElementInterface.


$14

Price includes 1 year of updates.
$5/year per site for updates after that.


Package Name

To install this plugin, search for its package name on the Plugin Store and click “Install”.


Information

  • Version 1.0.3
  • Last Update 1/10/2019
  • Active Installs 72
  • Compatibility Craft 3
  • License Craft
  • Categories Templating, Utilities

Report an issue