I'm working on a WordPress site that has two external javascript files load about half-way down the page. The files are badges from Reddit and Digg, and often add about 4-8 seconds to the total loading time of page — while also preventing the bottom 50% of the page from loading too.
The Digg and Reddit javascripts render an <iframe>
(which I assume needs to load completely before the rest of my web page is loaded), and thus adds a big amount of extra load time.
I tried moving the <script>
tags to the bottom of the page, right before </body>
, but the badges render just below the footer instead of where they need to be.
How can I force these two external javascript files to load last, but still render where they need to?