NN = (navigator.appName.indexOf("Netscape")>-1) ? 1 : 0;
NN4 = (NN && parseInt(navigator.appVersion)==4) ? 1 : 0;
NN6 = (NN && parseInt(navigator.appVersion)>4) ? 1 : 0;
/*cambiare questo numero al cambiare dei livelli da mostrare */
var totalLayersInLoop=8;
var layerNumShowing=1;
function init(){
if (NN4) {
layerStyleRef="layer.";
layerRef="document.layers";
styleSwitch="";
} else if (NN6) {
layerStyleRef="layer.style.";
layerRef="document.getElementById";
styleSwitch=".style";
} else {
layerStyleRef="layer.style.";
layerRef="document.all";
styleSwitch=".style";
}
}
function showLayerNumber(number){
var layerNumToShow=number;
hideLayer(eval('"layer' + layerNumShowing+'"'));
showLayer(eval('"layer' + layerNumToShow+'"'));
layerNumShowing=layerNumToShow;
}
function showLayer(layerName){
if (NN6) {
eval(layerRef+'("'+layerName+'")'+styleSwitch+'.vi sibility="visible"');
} else {
eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="visible"');
}
}
function hideLayer(layerName){
if (NN6) {
eval(layerRef+'("'+layerName+'")'+styleSwitch+'.vi sibility="hidden"');
} else {
eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="hidden"');
}
}