Mobile Menu and jquery 2.2.4
7 years 2 weeks ago #46625
by Fastserv
Mobile Menu and jquery 2.2.4 was created by Fastserv
On a site with Joomla 3.8.3 and PHP 7.1 I try to use jquery 2.2.4 wich works except fpr MaxiMenuMobile.
There I get this errors:
ReferenceError: jQuery is not defined - maximenuckmobile.js:566:1
TypeError: $(...).MobileMaxiMenu is not a function
Is there a way to make this work?
Regards,
Stefan
There I get this errors:
ReferenceError: jQuery is not defined - maximenuckmobile.js:566:1
TypeError: $(...).MobileMaxiMenu is not a function
Is there a way to make this work?
Regards,
Stefan
Please Log in or Create an account to join the conversation.
7 years 2 weeks ago #46626
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Mobile Menu and jquery 2.2.4
Hi
give me the url of your page, this is not a problem from the jquery version but that you are loading it the wrong way.
You shall use the JLayout override to load your own version of jquery, and not call it once time more in the page
CEd
give me the url of your page, this is not a problem from the jquery version but that you are loading it the wrong way.
You shall use the JLayout override to load your own version of jquery, and not call it once time more in the page
CEd
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
7 years 2 weeks ago #46629
by Fastserv
Replied by Fastserv on topic Mobile Menu and jquery 2.2.4
The URL:
tvduelmen.de.swmserver.de/index.php
I did it this way in the template:
First:
unset($doc->_scripts[JURI::root(true).'/media/jui/js/jquery.min.js']);
Then:
$doc->addScript(' code.jquery.com/jquery-2.2.4.min.js " integrity="sha256-BbhdlvQf/xTY9gja0Dq3HiwQF8LaCRTXxZKRutelT44=" crossorigin="anonymous');
tvduelmen.de.swmserver.de/index.php
I did it this way in the template:
First:
unset($doc->_scripts[JURI::root(true).'/media/jui/js/jquery.min.js']);
Then:
$doc->addScript(' code.jquery.com/jquery-2.2.4.min.js " integrity="sha256-BbhdlvQf/xTY9gja0Dq3HiwQF8LaCRTXxZKRutelT44=" crossorigin="anonymous');
Please Log in or Create an account to join the conversation.
7 years 2 weeks ago #46630
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Mobile Menu and jquery 2.2.4
the problem is that there are 2 scripts loaded before your jquery call
my question, why do you need another jquery version ?
I'm calling my script with "onAfterDispatch".<script src="/media/system/js/caption.js?0c582ce921f2e78ca1e70249b07d8459"></script>
<script src="/plugins/system/maximenuckmobile/assets/maximenuckmobile.js"></script>
my question, why do you need another jquery version ?
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
7 years 2 weeks ago #46632
by Fastserv
Replied by Fastserv on topic Mobile Menu and jquery 2.2.4
I use Bootstrap 4 on that Template and and need it for a few modules.
Please Log in or Create an account to join the conversation.
7 years 2 weeks ago #46633
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Mobile Menu and jquery 2.2.4
try to change teh event in my plugin, for example "onBeforeDispatch" and see if it works
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
Time to create page: 0.229 seconds