window.onload = function() { for (var imgs = document.getElementsByTagName('img'),i=0,l=imgs.length; i