By Fiorino De Santo on Thursday, 05 May 2016
Posted in Technical Issues
Likes 0
Views 315
Votes 0
Hi,

After upgrade to ED 4 I have found several Javascript problems, after some research I have found a new parameter enabled by default called "Load jQuery (Recommended to leave it on)". After disable this all seems to works.

Why ED load own jQuery instance? I think is better to use JUI jQuery (load with Joomla API) to keep compatibility with all Joomla components and templates, Joomla default components and all templates already load this.
Can you confirm that all ED javascript will works with default Joomla jQuery?
Hey there,

There will only be 2 instances of jQuery if you turn on the "Load jquery" feature. Also, mind you that some extensions / plugins / modules does alter the "jquery" object and it will result in EasyDiscuss failing. The only way to fix this is to render our own jquery as well
·
Friday, 06 May 2016 00:43
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey Fiorino,

Older Joomla versions (Joomla 2.5) does not have jQuery built in. If we do not include jQuery, this will not work Another reason is because some Joomla templates does not render Joomla's jQuery framework and rely on either mootools or their own frameworks. This is why there is a settings for this.

If you are on the latest Joomla version and the template loads Joomla's jquery library, then feel free to turn it off
·
Friday, 06 May 2016 00:16
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi,
thanks for your super quick reply.

this is only suggestion:)

I think the best way is to load jQuery with Joomla API, so

if "Load jQuery" is enabled
{
if J >= 3.0 {
- JHtml::_('jquery.framework');
- Load ED javascript without jquery
}
if J < 3.0 {
- Load ED javascript with jquery
}
}
else
{
Load ED javascript without jquery
}


Joomla 2.5 support is ended, I know, anyway this is a good market for you. But now you risk only incompatibilities and inefficiencies,

simple example (most of cases):
- install Joomla
- install ED
Results: 2 jQuery instances with protostar template?!?
·
Friday, 06 May 2016 00:32
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi,
yes, this is a good point of view...
·
Friday, 06 May 2016 01:07
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks
·
Friday, 06 May 2016 11:14
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post