Gaya / queryloader2

Version of the QueryLoader by Gaya Kessler. Preload images with ease.
http://blog.gaya.ninja/articles/queryloader2-preload-your-images-with-ease/
MIT License
718 stars 231 forks source link

Not showing percent. Error of Uncaught TypeError: Cannot read property 'indexOf' of null #128

Closed packytagliaferro closed 9 years ago

packytagliaferro commented 9 years ago

I am trying to use the plugin as described

<script type="text/javascript"> window.addEventListener('DOMContentLoaded', function() { new QueryLoader2(document.querySelector("body"), { barColor: "#efefef", backgroundColor: "#111", percentage: true, barHeight: 1, minimumTime: 200, fadeOutTime: 1000 }); }); </script>

But it wont work. It looked like it worked one time but only loaded to 27%. But now I just get this error:

Uncaught TypeError: Cannot read property 'indexOf' of null i.hasGradient i.findImageInElement i.getImageSrcs i.findAndPreload (anonymous function)

I am using css background images a lot and fullpage.js. Does that matter??

Gaya commented 9 years ago

Do you have an URL I can check to see what's happening? Thanks.

packytagliaferro commented 9 years ago

http://secure.friendlysoftware.com/~tpacky51/residential.html

Gaya commented 9 years ago

The latest version should solve this problem. Try to upgrade to 3.0.13

packytagliaferro commented 9 years ago

I upgraded and still getting that same error on that link I sent.

Gaya commented 9 years ago

Okay. I'll look into this a bit further

visnetje commented 9 years ago

I am seeing a similar error as the one described in the subject here. Gaya, were you able to find and resolve this issue?

Gaya commented 9 years ago

Sorry, haven't had the time yet.