WEB SYSTEMS PRO
E-commerce platform
Featured Products of Category
Featured Products of Category
Syrnik
Syrnik
Featured Products of Category
Featured Products of Category
Featured Products of Category
Featured Products of Category
Featured Products of CategoryFeatured Products of CategoryFeatured Products of CategoryFeatured Products of Category
€9.80
€0

* Net price, 23% VAT must be added

SKU:WSP-370-PL
Features
License
Web Systems Pro
Version
1.0.0.3.wsp
Update
06/08/2025
All features

Description and Settings

"Featured Products of Category" plugin generates and displays lists of favorite products for a given category. The functionality of plugins is similar to the dynamic lists built into the Shopy-Script application, but product selection for the list is made from the current or specified category, not from all store products.

Displaying a list above the main product list in a category helps draw customer attention to new products, best-selling items, discounted offers on products within the category being viewed by a potential customer.

Lists are created without sorting parameters and category filters, even if the visitor has set them.

The maximum number of products per list is defined in the plugins settings. Avoid unnecessarily large numbers; 6-12 products per list will be sufficient. The actual number of products displayed may be less than specified if the category does not contain enough products. The list can even be empty.

Plugin generates four types of lists:

  • New products - a list of the newest products in the given category. This is a list of products from the category, sorted in descending order by creation date. The newest product appears first. You can also set a day limit after which a product is no longer considered new. Products created earlier than this limit will not be included.
  • Best selling - a list of products sorted in descending order by sales count. Products with the same sales count are sorted alphabetically by name.
  • Top rated - products sorted in descending order by customer rating. Products with the same rating are also sorted alphabetically by name.
  • Best buys - products with the highest numeric discount. The discount is calculated as the difference between the "crossed-out" price and the sale price. Products with the same discount are also sorted alphabetically by name. Products without a discount (discount equal to zero or negative) and products without a crossed-out price are not included in the list.


Settings store settings affecting plugins operation

  • Sales of out-of-stock products. If users are allowed to order out-of-stock products, such products will be included in the lists. If out-of-stock items are not allowed for sale, they will not appear in the lists.
  • Displaying products from subcategories. Products are displayed according to the "Include products from subcategories" setting. If the category settings allow showing products from subcategories, those products will be considered when generating lists. Otherwise, they will not.


Managing list display

Built-in theme functions

The embedded theme includes three variables, two of which - wa_theme_url and wa_theme_path - are similar to the template variables of the main application themes. They can be used, for example, to include a standard template from the project theme for displaying lists, typically list-thumbs.html or list-thumbs-mini.html. This can help unify the appearance with other parts of the theme.

The embedded theme also passes the lists variable as an associative array with list identifiers as keys and products as values.

Allowed keys are: newest, top_rated, top_selling and best_buys.

array(
'newest' => array(/* product array */),
'top_rated' => array(/* product array */),
'top_selling' => array(/* product array */),
'best_buys' => array(/* product array */)
);


Each list has the same format as the product array in a category or product list.


Display using the frontend_category hook

The built-in theme is displayed at the location defined by the frontend_category hook. In the plugins settings, you can optionally specify that the theme is shown only on the first category page if you use pagination. You can also completely disable hook handling.


Displaying the built-in theme in a custom location

If you want to display the result of plugins using the built-in theme in any location on the category page, you can use the method shopFeaprocatPlugin::render($category_id), replacing $category_id with the category ID (it can be different from the current one, but why would you do that?)

Example call from the category.html file:
{shopFeaprocatPlugin::render($category.id)}


Retrieving data without using the built-in theme

You can simply retrieve the data as an array without using the built-in theme or plugin options. To do this, call the method shopFeaprocatPlugin::getProducts($options), where $options is an array with settings. The settings array format:

$options = array(
'category_id' => category_id /* Category ID. Required key */
'list_types' => array( /* Array of requested lists. The list identifier should */
'newest'=> 1, /* be the array key, and the value should be */
... /* greater than 0 */
),
'max_products' => 12, /* Maximum number of products per list, default is 12 */
'days_new' => 30 /* Limit for the "age" of new products; set */
/* 0 to disable. Default is 30 days */
)


More o wtyczce "Featured Products of Category": Updates
Technical specifications
Developed for
Shopy-Script
Localization settings
English, Polish, Russian
UI backend support
1.3, 2.0
Software type
Plugin
Free
No
Developer and version plugins
Developer
Syrnik
License
Web Systems Pro
Version
1.0.0.3.wsp
Update
06/08/2025
Loading...
Loading...