function silentErrorHandler() {return true;} window.onerror=silentErrorHandler; // Requires mootools // adds onmouseover to all images with // class .roll window.addEvent('domready',function(){ $$('img.roll, input.roll').each(function(img) { var src = img.getProperty('src'); var extension = src.substring(src.lastIndexOf('.'),src.length) img.addEvent('mouseenter', function() { img.setProperty('src',src.replace(extension,'.roll' + extension)); }); img.addEvent('mouseleave', function() { img.setProperty('src',src); }); }); var i = 0; });