0
Hi Germi,
I'd like to test if deferrign the some scripts from your component will affect how my site loads but i'm not sure how to...
I'd like to add 'defer' to the js codes from
plugins/muscolplayers/jwplayer/jwplayer/jwplayer.js (167.9KiB)
plugins/content/hwdjwplayer/assets/jwplayer7/jwplayer.js (151.8KiB)
But where are these loaded? I'm looking for the code but dont know which file they are in
I'd like to test if deferrign the some scripts from your component will affect how my site loads but i'm not sure how to...
I'd like to add 'defer' to the js codes from
plugins/muscolplayers/jwplayer/jwplayer/jwplayer.js (167.9KiB)
plugins/content/hwdjwplayer/assets/jwplayer7/jwplayer.js (151.8KiB)
But where are these loaded? I'm looking for the code but dont know which file they are in
Responses (5)
-
Accepted Answer
-
Accepted Answer
-
Accepted Answer
-
Accepted Answer
0this indicates how: https://api.joomla.org/cms-3/classes/jdocument.html#method_addscript
you have to find at the end:
$document->addScript($jwplayer_root.'jwplayer.js');
and change it for
$document->addScript($jwplayer_root.'jwplayer.js', 'text/javascript', true, true);
or whatever you need.
Your Reply
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »