Magento 1.9 – Load External Script Async the Right Way

javascriptlayoutmagento-1.9xml

How can I load external scripts async (and preferably also defer). I know I can add attributes to local scripts like this:

<action method="addJs"><script>js/script.js</script><params>async defer</params></action>

But how do I load external scripts? The method above does not work for external scripts.

Best Answer

You can't natively you must use a third party Module, you can try this

http://inchoo.net/magento/how-to-add-external-javascript-css-file-to-magento/

Related Topic