preloadFlag=1; nb='_over'; activation='_active'; function on(button) { if(preloadFlag==1 & button.src.indexOf(activation)<=0){ x = button.src; y = x.substring(0,x.length-4); ext = x.substring(x.length-4,x.length); act=y+nb+ext; button.src=act; } } function off(button) { x = button.src; ext = x.substring(x.length-4,x.length); tocut = x.length-(nb.length+ext.length); if (x.indexOf(nb)>0) { y = x.substring(0,tocut); act = y+ext; button.src=act; } } function topnav() { document.write('