UPDATES EasyBlog 6.0.11 Released! Update to the latest version now!

Helpdesk

Your Time
Our Time
Response Time
24 — 48 hours
We strive to provide the fastest ever response possible. However, we are not super beings.

Allow at least 24 — 48 hours
  Support is offline
Our team is away during the weekend. Some answers may already be available on our documentation

Rest assured that we will get back to your posts as soon as the week starts!
  Support is offline

MetaMan causes issue with mobile menu

Stefan Suck · ·
6:53 PM Monday, 19 February 2018
Normal
Greetings!

Our website uses the bootstrap framework and jQuery. After activating MetaMan however, we noticed that the mobile menu (hamburger symbol) doesn't work properly. It reacts only on the second mouseclick and behaves irregularily afterwards when using the jQuery's toggle function.
We managed to pin down the cause of this in the onAfterInitialise-Function in the PlgSystemMetaman-Class. On line 62, following code is executed:


// Ensure that jQuery is enabled on the site
if (MM::requirejQuery()) {
$this->doc->addScript($this->baseurl . '/plugins/system/metaman/assets/scripts/jquery-3.1.0.min.js');
} else {
JHtml::_('bootstrap.framework');
}


As we understand, this checks if a current version of jQuery is used. If the jQuery version is 1 or 2 (checked in requirejQuery), it adds the jQuery-3-Script. Otherwise, it includes the bootstrap framework.
This causes a conflict, as bootstrap is already used on our side, which seems to cause the toggle-function of jQuery to be bound twice to the menu button, which leads to the strange behavior.
This can be simply tested by commenting out the
JHtml::_('bootstrap.framework');
line. In doing so, the mobile menu behaves normally.

The only solution we found was to either edit the plugin (which we want to avoid), make an override for our own jQuery-library (which may cause unwanted side-effects) or use a custom toggle-script (which seems to be unneeded effort).

Do you have any better idea how to fix this?
The replies under this section are restricted to logged in users or users with an active subscription with us