You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification
<?php
defined('_JEXEC') or die;
use Joomla\CMS\Factory;
use Joomla\CMS\Plugin\CMSPlugin;
class PlgSystemVmCartAjax extends CMSPlugin
{
public function __construct(&$subject, $config = array())
{
parent::__construct($subject, $config);
if (version_compare(JVERSION, '4.0.0', 'ge') && method_exists($this, 'registerLegacyListener')) {
$this->registerLegacyListener('plgVmOnUpdateCart');
}
}
public function plgVmOnUpdateCart(&$cart, &$force, &$html)
{
// Reindex cart products to ensure sequential keys starting from 0
if (isset($cart->products) && is_array($cart->products)) {
$cart->products = array_values($cart->products);
}
}
public function onAfterInitialise()
{
}
}
<?xml version="1.0" encoding="UTF-8"?>
<extension version="3.9" type="plugin" group="system" method="upgrade">
<name>VirtueMart Ajax Cart / Reindexer plugin</name>
<author>YUZI</author>
<creationDate>2025-10-28</creationDate>
<copyright>(C) 2025 yuzi. All rights reserved.</copyright>
<license>GNU General Public License version 3 or later</license>
<authorEmail>info@yuzi.nl</authorEmail>
<authorUrl>www.yuzi.nl</authorUrl>
<version>1.0.0</version>
<description>Gets Ajax Cart and reindexes cart contents.</description>
<files>
<filename plugin="vmcartajax">vmcartajax.php</filename>
</files>
<config>
</config>
</extension>
Quote from: psm on November 06, 2025, 21:51:38 PMThe files vm2front.js and jquery.vmtrigger.js are missing from the Network tab (they do not load).
Page created in 0.126 seconds with 13 queries.