Salve a tutti, io ho questo script che dovrebbe usare un css diverso a seconda del browser usato
codice:
function bsniff(){
  this.dom = document.getElementById?1:0;
  this.ie = (document.all && !this.dom)?1:0; ///Internet Explorer 4
  this.IE = (this.dom && document.all)?1:0; ///explorer 5 e superiori
  this.n4 = (document.layers && !this.dom)?1:0;///Communicator netscape)
  this.NN = (this.dom && !document.all)?1:0;////Netscape Navigator (6, 7+)
  this.opera = window.opera?1:0;///Opera
  return this;
}

var cssie = "stile_ie4.css"
var cssIE = "stile.css"
var cssNN = "stile_netscape.css"
var cssOpera = "stile_opera.css";
bw = new bsniff();

document.write("<link rel=\"stylesheet\" type=\"text/css\" href=\"");

if(bw.ie){
   document.write( cssie +"\">")
}
else if(bw.IE){
   document.write(cssIE + "\">")
}
else if(bw.NN){
	document.write(cssNN + "\">");
}
else if(bw.opera){
	document.write(cssOpera + "\">");
}
solo che aprendo la pagina con opera, continua ad usare quello di IE 6, come mai?