I’m coding a website that displays picture albums, the page is loading the thumbs and applies white overlays on each picture before they are fully loaded.
I coded this in local and it works fine.
But uploading the files on my server and loading the page brings few errors of display, some white overlay are not fading out because the jQuery load function is not triggered since images load before the script is loaded and being applied.
The solution would be to apply white overlay only on images that are still loaded when the jQuery script is being executed.
My question is how to know if a specific element in the page is still being fetched or has completely been rendered on the screen ?
NOTE : here’s the page http://www.benjamindegenne.com/portfolio/numeric/upper-playground/
https://github.com/desandro/imagesloaded – images loaded jQuery plug in will do that for you 😉