Shadowbox.init({ skipSetup: false, adapter: 'base', language: 'nl', overlayColor: '#9B2C2E', overlayOpacity: '0.9', handleOversize: 'resize', players: ["img", "swf", "html", "iframe"] }); function init(){ $$('.flashimage').each(function(el,i){ set_highlight(el); }); set_highlight($('submit')); } function set_highlight(el){ el.addEvent('mouseenter', function(){ if(!el.hasClass('fading')){ el.addClass('fading'); new Fx.Tween(el, {duration: 75, onComplete: function(){ new Fx.Tween(el, {duration: 250, onComplete: function(){ el.removeClass('fading'); }}).start('opacity', 0.5, 1); }}).start('opacity', 1, 0); } }); } window.addEvent('load', init);