Download the PHP package mage2kishan/module-hero-slider without Composer

On this page you can find all versions of the php package mage2kishan/module-hero-slider. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package module-hero-slider

Magento 2 Hero Slider

Panth Hero Slider adds an admin-managed image carousel to a Magento 2 storefront. Slides are grouped into sliders, each slider has an identifier and a store-view assignment, and each slide carries a desktop image, an optional mobile image, a link, and a call-to-action button with its own colours. The carousel is rendered by Splide.js in a center-focused layout that shows several slides at once on desktop and one slide with pagination dots below a configurable breakpoint.

By default the module injects the slider with identifier homepage_hero into the content container of the CMS home page; it can also be placed on any page through a widget or layout XML. Views and clicks are counted per slide and shown in the admin. The template ships its own CSS and does not depend on theme JavaScript, so it works on both Hyva and Luma themes.

Product page: kishansavaliya.com/magento-2-hero-slider.html

Features

Compatibility

Platform Versions
Magento Open Source 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 (as published on the product page)
Adobe Commerce 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8 (as published on the product page)
PHP 8.1, 8.2, 8.3, 8.4 (~8.1.0||~8.2.0||~8.3.0||~8.4.0 in composer.json)
Themes Hyva and Luma

Composer constraints on Magento packages: magento/framework ^103.0, magento/module-backend ^102.0, magento/module-cms ^104.0, magento/module-config ^101.2, magento/module-media-storage ^100.4, magento/module-store ^101.0, magento/module-ui ^101.0, magento/module-widget ^101.2.

Requirements

Installation

setup:di:compile is only needed in production mode. setup:static-content:deploy is required because the module ships view/frontend/web/css/hero-slider.css.

Check that the module is enabled:

setup:upgrade creates the database tables and runs the CreateDefaultSlider data patch, which inserts the "Home Page Hero" slider (homepage_hero) assigned to all store views and attaches any slide without a slider to it.

Configuration

Admin path: Stores > Configuration > Panth Infotech > Hero Slider. This module labels the shared panth tab "Panth Infotech"; Panth_Core labels the same tab "Panth Extensions", so the tab name shown depends on which definition Magento loads last. The section is also reachable from the sidebar item "Panth Infotech" > "Hero Slider" > "Configuration". Viewing the section requires the ACL resource Panth_HeroSlider::config.

General

Setting Default What it does
Enable Hero Slider Yes Master switch. When No, every slider block renders nothing.
Autoplay Yes Advances slides automatically.
Autoplay Interval (ms) 22000 Time each slide is shown before advancing. Shown only when Autoplay is Yes.
Slides Per Page (Desktop) 3 Number of slides visible at once above the mobile breakpoint.
Show Arrows (Desktop) Yes Shows previous/next arrows above the mobile breakpoint. Arrows are always hidden below it.
Mobile Breakpoint (px) 1025 Below this viewport width the carousel shows one slide per page with pagination dots and no arrows.
Auto-inject on CMS Home Page Yes Renders the homepage_hero slider at the top of the home page content container. Set to No to place the slider manually.
Check Active and Store View for Layout Slider ID No When Yes, a slider_id block argument from layout XML is only rendered if the slider is active and assigned to the current store view or All Store Views. No keeps the earlier behaviour: a layout slider_id is rendered without these checks.

Analytics

Setting Default What it does
Track Views and Clicks Yes Enables the tracking script in the storefront template and the tracking endpoint. When No, the endpoint ignores incoming events. Counts are stored per slide, day, store view, event type and device type; no personal data is recorded.
Retention (days) 365 Statistics rows older than this are deleted by the daily cron job. Shown only when tracking is Yes; default scope only.
Tracking Requests Per IP Per Minute 60 Tracking requests above this number from one IP address within a minute are answered with 429 and not counted. 0 turns the limit off.

Config paths: panth_heroslider/general/enabled, panth_heroslider/general/autoplay, panth_heroslider/general/interval, panth_heroslider/general/per_page, panth_heroslider/general/show_arrows, panth_heroslider/general/mobile_breakpoint, panth_heroslider/general/auto_inject_homepage, panth_heroslider/general/validate_layout_slider_id, panth_heroslider/analytics/enabled, panth_heroslider/analytics/retention_days, panth_heroslider/analytics/rate_limit_per_minute. All fields except retention_days can be set at default, website and store-view scope. Invalid or empty numeric values fall back to 22000, 3 and 1025 respectively.

With the defaults the module is active immediately after installation: once at least one active slide is assigned to the homepage_hero slider, the carousel appears on the home page.

Managing sliders

Sidebar: "Panth Infotech" > "Hero Slider" > "Manage Sliders" (ACL Panth_HeroSlider::sliders). The grid lists ID, Name, Identifier, Store Views, Active and Updated, with a keyword search (name, identifier) and a mass "Delete" action. The form ("Slider" fieldset) has:

Managing slides

Sidebar: "Panth Infotech" > "Hero Slider" > "Manage Slides" (ACL Panth_HeroSlider::slides). The grid lists ID, Desktop Image, Title, Slider Group, Link URL, Button Label, Sort, Active, Views (30d), Clicks (30d), CTR (30d) and Updated, with a keyword search (title, button label, image alt text, link URL) and mass "Delete", "Enable" and "Disable" actions. The form has three fieldsets:

The slide edit page also shows the "Performance" panel described under Features. Deleting a slider sets slider_id of its slides to NULL; deleting a slide removes its statistics rows.

Usage

Automatic home page placement

With "Auto-inject on CMS Home Page" set to Yes, view/frontend/layout/cms_index_index.xml adds the block panth.heroslider.home (Panth\HeroSlider\Block\Slider, template Panth_HeroSlider::slider.phtml) to the content container with before="-", using the identifier homepage_hero.

Widget

Insert the widget "Panth Hero Slider" (panth_heroslider_widget) in a CMS page, CMS block or widget instance. It has one parameter:

Parameter Required Description
Slider Identifier (slider_identifier) Yes Identifier of the slider to render, for example homepage_hero.

The widget class is Panth\HeroSlider\Block\Widget\Slider, which extends the storefront block and uses the same template.

Layout XML

A slider_id argument (integer) is also accepted and takes precedence over slider_identifier. By default a slider_id is rendered without checking that the slider is active or assigned to the current store view; set "Check Active and Store View for Layout Slider ID" to Yes to apply the same checks as for identifiers. When neither argument is given the block uses homepage_hero.

Storefront behaviour

Cron

Job Schedule Class Action
panth_heroslider_prune_stats 23 3 * * * Panth\HeroSlider\Cron\PruneStats When "Track Views and Clicks" is Yes, deletes rows from panth_hero_slider_stat whose event_date is older than "Retention (days)" and logs the number removed.

Templates

Developer Notes

Uninstallation

The four panth_hero_slider_* tables, the panth_heroslider/* rows in core_config_data, the CreateDefaultSlider entry in patch_list and uploaded images under pub/media/panth/heroslider/ remain after these steps and must be removed manually if no longer wanted. Widget instances and CMS content that reference the widget also remain.

Support

License

Free and open source under the MIT License. See LICENSE.txt.

Changelog

See CHANGELOG.md.

Links


All versions of module-hero-slider with dependencies

PHP Build Version
Package Version
Requires php Version ~8.1.0||~8.2.0||~8.3.0||~8.4.0
magento/framework Version ^103.0
magento/module-backend Version ^102.0
magento/module-cms Version ^104.0
magento/module-config Version ^101.2
magento/module-media-storage Version ^100.4
magento/module-page-cache Version ^100.4
magento/module-store Version ^101.0
magento/module-ui Version ^101.0
magento/module-widget Version ^101.2
mage2kishan/module-core Version ^1.0.17
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mage2kishan/module-hero-slider contains the following files

Loading the files please wait ...