ishome=0;
// BrowserCheck Object
function BrowserCheck() {
        var b = navigator.appName
        if (b=="Netscape") this.b = "ns"
        else if (b=="Microsoft Internet Explorer") this.b = "ie"
        else this.b = b
        this.version = navigator.appVersion
        this.v = parseInt(this.version)
        this.ns = (this.b=="ns" && this.v>=4)
        this.ns4 = (this.b=="ns" && this.v==4)
        this.ns5 = (this.b=="ns" && this.v==5)
        this.ie = (this.b=="ie" && this.v>=4)
        this.ie4 = (this.version.indexOf('MSIE 4')>0)
        this.ie5 = (this.version.indexOf('MSIE 5')>0)
        this.ie6 = (this.version.indexOf('MSIE 6')>0)
		this.ie7 = (this.version.indexOf('MSIE 7')>0)
        this.min = (this.ns||this.ie)
        this.comp = (this.ns5||this.ie5||this.ie6)
		this.platf = navigator.platform.toUpperCase();
		this.linux = (this.platf.indexOf('LINUX')!=-1);
}
is = new BrowserCheck()

function externalLinks() { 
 if (!document.getElementsByTagName) return; 
 var anchors = document.getElementsByTagName("a"); 
 for (var i=0; i<anchors.length; i++) { 
   var anchor = anchors[i]; 
   relatt=new String(anchor.getAttribute("rel"));
   if (anchor.getAttribute("href") && relatt.indexOf("external")!=-1) 
     anchor.target = "_blank"; 
 } 
}

function showcredits(onoff){
	creditslayer=document.getElementById("credits");
	if(onoff==1) creditslayer.style.display="block";
	else creditslayer.style.display="none";
}

//carga un CSS en caso de tener Javascript activado
function javascript_css(){
	document.write("<link rel= \"stylesheet\" type=\"text/css\" media=\"all\" href=\"/styles/javascript.css\" />");
}

//preload
function simplePreload()
{ 
  var args = simplePreload.arguments;
  document.imageArray = new Array(args.length);
  for(var i=0; i<args.length; i++)
  {
    document.imageArray[i] = new Image;
    document.imageArray[i].src = args[i];
  }
}

function show(id){
	estilo=document.getElementById(id).style.display;
	if(estilo=="block") document.getElementById(id).style.display="none";
	else  document.getElementById(id).style.display="block";
}