var LANG_URLS = new Array("cz", "da", "de", "es", "en", "fr", "nl");
var LANG_TITLES = new Array( "Cesky", "Dansk", "Deutsch", "Espa&#241;ol", "English","Fran&#231;ais", "Nederlans");

var navTypes = new Array("navTypes", "types.html", "images/nav/navTypesOn.gif", "images/nav/navTypesOff.gif");
var navSelf = new Array("navSelf", "self.html", "images/nav/navSelfOn.gif", "images/nav/navSelfOff.gif");
var navTreatments = new Array("navTreatments", "treatments.html", "images/nav/navTreatmentsOn.gif", "images/nav/navTreatmentsOff.gif");
var navAbout = new Array("navAbout", "about.html", "images/nav/navAboutOn.gif", "images/nav/navAboutOff.gif");
var navResources = new Array("navResources", "resources.html", "images/nav/navResourcesOn.gif", "images/nav/navResourcesOff.gif");
var subNavInterstitial = new Array("subNavInterstitial", "interstitial_type.html", "images/nav/subNavTypes_interstitialOn.jpg", "images/nav/subNavTypes_interstitialOff.jpg" );
var subNavRadiationInduced = new Array("subNavRadiationInduced", "radiationInduced_type.html", "images/nav/subNavTypes_radiationOn.jpg", "images/nav/subNavTypes_radiationOff.jpg" );
var subNavRecurrentBacterial = new Array("subNavRecurrentBacterial", "bacterial_type.html", "images/nav/subNavTypes_recurrentOn.jpg", "images/nav/subNavTypes_recurrentOff.jpg" );	
var subNavDownloads = new Array("subNavDownloads", "downloads.php", "images/nav/subNavResources_downloadsOn.jpg", "images/nav/subNavResources_downloadsOff.jpg");	

function copyWrite( type ){
	if( type == 'disclaimer' ){
		document.write( '<span class=\"footText\">&#169; 2006 Bioniche Pharma Group Limited, with all rights reserved. Cystistat is a trademark of Bioniche Teoranta, Ireland.</span>&nbsp;<span class="selectedNav">Disclaimer</span><span class=\"footText\">.<img src="../images/spacer.gif" width="1" height="16" border="0"></span>' );	
	}else{
		document.write( '<span class=\"footText\">&#169; 2006 Bioniche Pharma Group Limited, with all rights reserved. Cystistat is a trademark of Bioniche Teoranta, Ireland.</span>&nbsp;<a href=\"disclaimer.html\" class=\"nav\">Disclaimer</a><span class=\"footText\">.<img src="../images/spacer.gif" width="1" height="16" border="0"></span>' );			
	}
}

function disclamerText()
{
	s =  '<p class="darkBlueTitle">DISCLAIMER</p>';
	s += '<p>The information contained on this web site is intended for educational purposes only in regions where Cystistat has been approved. You may download or print material from the site for non-commercial, personal, or informational purposes if you reference Bioniche Pharma Group Limited ("Bioniche") as the copyright owner. Prior written permission from Bioniche is required to reproduce any of this site\'s content or images for commercial or public use in any medium.<p>';
	s += '<b>Links and Downloads</b><br>';
	s += 'This site links to sites that are not under Bioniche\'s control. None of the opinions or recommendations expressed on the websites listed are endorsed or vouched for by Bioniche Pharma Group Limited. They must be taken solely as the opinions of their authors.<p>';
	s += 'Bioniche expressly disclaims all liability and legal responsibility for the information contained or referenced in, posted by others in, or linked to these websites. No warranties may be implied, but all are expressly disclaimed to the full extent permitted by law.<p>';
	s += 'Electronic files and software downloaded over the internet can contain viruses and other risks, and Bioniche makes no guarantee that files downloaded from these websites or from the Bioniche site will be virus-free or will not cause computer problems.<p>';
	s += '<b>Copyrights and Trademarks</b><br>';
	s += 'This website (cystistat.com) is copyright © 2006 Bioniche Pharma Group Limited, with all rights reserved. Cystistat is a trademark of Bioniche Teoranta, Ireland. All other products, services, or company names mentioned on this site may be trademarks or trade names of their respective owners.<br><br><br></span>';
	
	document.write(s);
}

function changeImage(xSrc, xImage)
{
    document.images[xSrc].src = xImage;
}

function changeLanguage(xLang)
{
    url = window.location.href;
    url = url.substring(url.lastIndexOf('/'), url.length);
    
    document.location = "../"+ xLang + url;
}
	
function getLanguageMenu(xLang)
{
    document.write("<select onChange='changeLanguage(this.value)'>");
    for (i=0; i<LANG_URLS.length; i++)
    {
        document.write("<option ");
	if (LANG_URLS[i] == xLang)
	    document.write("SELECTED ");

	document.write("value='" + LANG_URLS[i] + "'>" + LANG_TITLES[i] + "</option>");
    }
    document.write("</select>");
}

function getMenuEntry(xNav, xLink)
{
    if (xLink)
	document.write( "<a href='"+ xNav[1] +"' onMouseOver=\"changeImage('"+xNav[0]+"','"+xNav[2]+"')\" onMouseOut=\"changeImage('"+xNav[0]+"','"+xNav[3]+"')\"><img name='"+ xNav[0] +"' src='"+ xNav[3] +"'  border='0'></a><br>");
    else	
        document.write( "<a href='"+ xNav[1] +"'><img name='"+ xNav[0] +"' src='"+ xNav[2] +"'  border='0'></a><br>");
}

function getUserMenu( xLocation ) 
{
  document.write( '<img src=\"../images/navTwoTone.gif\" width=\"256\" height=\"39\"><br>' );	
  if( xLocation == 'types' )
  {
	getMenuEntry(navTypes, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavInterstitial, true);
	getMenuEntry(subNavRadiationInduced, true);				        
	getMenuEntry(subNavRecurrentBacterial, true);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, true);
  }
  else if( xLocation == 'interstitial_type' )
  {
	getMenuEntry(navTypes, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavInterstitial, false);
	getMenuEntry(subNavRadiationInduced, true);				        
	getMenuEntry(subNavRecurrentBacterial, true);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, true);
  }
  else if( xLocation == 'radiationInduced_type' )
  {
	getMenuEntry(navTypes, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavInterstitial, true);
	getMenuEntry(subNavRadiationInduced, false);				        
	getMenuEntry(subNavRecurrentBacterial, true);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, true);

  }
  else if( xLocation == 'recurrentBacterial_type' )
  {
	getMenuEntry(navTypes, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavInterstitial, true);
	getMenuEntry(subNavRadiationInduced, true);				        
	getMenuEntry(subNavRecurrentBacterial, false);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, true);

  }
  else if( xLocation == 'resources' )
  {	
	getMenuEntry(navTypes, true);
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavDownloads, true);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );
  }
  else if( xLocation == 'downloads' )
  {
	getMenuEntry(navTypes, true);
	getMenuEntry(navSelf, true);
	getMenuEntry(navTreatments, true);
	getMenuEntry(navAbout, true);
	getMenuEntry(navResources, false);
	document.write( '<img src=\"../images/subNavTopBG.jpg\" width=\"256\" height=\"6\"><br>' );
	getMenuEntry(subNavDownloads, false);
	document.write( '<img src=\"../images/subNavBottomBG.jpg\" width=\"256\" height=\"7\"><br>' );		
  }
  else
  {
	getMenuEntry(navTypes, xLocation != 'type');
	getMenuEntry(navSelf, xLocation != 'self');
	getMenuEntry(navTreatments, xLocation != 'treatments');
	getMenuEntry(navAbout, xLocation != 'about');
	getMenuEntry(navResources, xLocation != 'resources');

  }
  document.write( '<img src=\"../images/navBottomHome.gif\" width=\"256\" height=\"20\">' );

}

function getHorizontalMenu(xHeader, xLang, xTitles, xUrls) 
{
    document.write("<table cellpadding='0' cellspacing='0'>");
    document.write("<tr>");
    document.write("<td colspan='11'><img src='../images/spacer.gif' width='1' height='7'></td>");
    document.write("</tr><tr>");
    if(xHeader)
    {
	document.write( '<td width=\"100%\">&nbsp;</td>');
	for (i=0; i<xTitles.length; i++)
	{
	   document.write("<td nowrap><a class='nav' href='"+ xUrls[i]+"'>"+ xTitles[i]+"</a></td>");
	   document.write("<td><img src=\"../images/spacer.gif\" width=\"10\" height=\"1\"></td>"); 
	}
	document.write("<td nowrap>");	
	getLanguageMenu(xLang);
	document.write("</td>");
   }
   else
   {
        for (i=0; i<xTitles.length; i++)
	{
	    document.write("<td nowrap><a class='nav' href='"+ xUrls[i]+"'>"+ xTitles[i]+"</a></td>");
	    document.write("<td><img src=\"../images/spacer.gif\" width=\"10\" height=\"1\"></td>"); 
	}
	document.write( '<td width=\"100%\">&nbsp;</td>' );
   }

   document.write("</tr><tr>");
   document.write("<td colspan='11'><img src='../images/spacer.gif' width='1' height='7'></td>");
   document.write("</tr>");
   document.write("</table>"); 
}

function openResource(xLang)
{
	if (xLang == 'fr')
	{
		s = "En cliquant sur les liens, vous quitterez le site Cystistat.\n\n";
		s += "Aucune des opinions ou recommandations formulées sur lesdits sites Internet n’est approuvée ou confirmée par Bioniche Pharma Limited. Ces opinions et recommandations n’engagent que leurs auteurs. ";
		s += "Bioniche décline expressément toute responsabilité et obligation légale concernant les informations contenues ou mentionnées sur ces sites Internet de męme que les informations publiées par des tiers ou accessibles ŕ partir de liens présents sur lesdits sites. Bioniche ne fournit aucune garantie implicite concernant ces informations, et décline expressément toute responsabilité en la matičre, dans les limites autorisées par la loi. ";
		s += "Les fichiers électroniques et logiciels téléchargés sur Internet peuvent contenir des virus et autres risques. Bioniche ne garantit en aucun cas que les fichiers téléchargés sur ces sites Internet sont exempts de virus ou sans danger pour votre ordinateur.";
		s += "\n\n";
		s += "J’ai bien lu ces mentions légales.";
	}
	else if (xLang == 'de')
	{
		s = "Mit der Wahl dieses Links verlassen Sie die Cystistat Webseite.\n\n";
		s += "Keine der  Meinungen oder Empfehlungen auf den verlinkten Webseiten sind  von Bioniche auf ihre Richtigkeit hin überprüft worden und  stellen keine  Zustimmung zu deren Inhalt seitens Bioniche dar. Sie sind ausschließlich als Meinungen ihrer Urheber zu betrachten. ";
        s += "Bioniche schließt  ausdrücklich jegliche Haftung und gesetzliche Verantwortung für die Informationen  aus, die auf diesen Webseiten  enthalten sind, auf die dort verwiesen, von Dritten dort publiziert oder über weitere Links zugänglich gemacht werden. ";
		s += "Bioniche gewährt keine Garantie bezüglich dieser Informationen und schliesst ausdrücklich jegliche Haftung entsprechend dem gesetzlichen Rahmen aus. Bioniche  übernimmt keine Gewähr, dass die Links unverändert in gleichbleibender Qualität zu einem Thema informieren. Das Herstellen einer Verbindung zu diesen Webseiten geschieht auf eigene Gefahr des Benutzers ";
		s += "Elektronische Dateien und Programme, die aus dem Internet heruntergeladen werden, können Viren und andere Gefährdungen enthalten. Bioniche gewährt keine Garantie, dass Dateien, die von diesen Webseiten heruntergeladen werden frei von Viren sind oder keine Computerprobleme verursachen könn.";	
	}
	else if (xLang == 'es')
	{
		s = "Accediendo a los links abandonará el website de Cystistat.\n\n";
		s += "Ninguna de las opciones o recomendaciones expresadas en las Webs enlazadas tienen que estar aprobadas ni compartir la opinión de Bioniche. Deben interpretarse por separado, como opiniones propias de su autor. ";
		s += "Bioniche no se responsabiliza de la información contenida o expresada o publicada por otros, o enlazada a esta Web. La información no puede estar certificada, ya que Bioniche declina expresamente su responsabilidad en los límites permitidos por la ley. ";
		s += "Los archivos electrónicos y softwares descargados de Internet pueden contener virus y otros riesgos. Bioniche no garantiza que los archivos descargados de estas Webs estén libres de virus o no puedan causar ningún problema al ordenador del usuario.";
	}
	else if (xLang == 'cz')
	{
		s = "Kliknutím na n"+ String.fromCharCode(283) +"který z odkaz? opustíte stránku spole"+String.fromCharCode(269)+"nosti Cystistat.\n\n";
		s += "Spole"+String.fromCharCode(269)+"nost Bioniche Pharma Limited nezastává žádné z názor? ani doporu"+String.fromCharCode(269)+"ení uvedených na odkazovaných stránkách a neru"+String.fromCharCode(269)+"í za n"+String.fromCharCode(283)+". Tyto názory a doporu"+String.fromCharCode(269)+"ení musejí být považovány výlu"+String.fromCharCode(253)+"n"+String.fromCharCode(283)+" za stanoviska jejich autor"+String.fromCharCode(367)+". ";
		s += "Bioniche se výslovn"+String.fromCharCode(283)+" z"+String.fromCharCode(253)+"íká jakéhokoli ru"+String.fromCharCode(269)+"ení "+String.fromCharCode(269)+"i právní odpov"+String.fromCharCode(283)+"dnosti za informace obsažené na t"+String.fromCharCode(283)+"chto stránkách, za informace, na n"+String.fromCharCode(283)+"ž tyto stránky odkazují, za informace, které na nich jiné osoby zve"+String.fromCharCode(345)+"ejní, i za informace, které na tyto stránky odkazují. Nelze od nich odvozovat žádné záru"+String.fromCharCode(269)+"ní nároky. Veškeré záruky se výslovn"+String.fromCharCode(283)+" odmítají v plném rozsahu umožn"+String.fromCharCode(283)+"ném zákonem. ";
		s += "Elektronické soubory a software stažené z internetu mohou obsahovat viry a jiná rizika. Bioniche nezaru"+String.fromCharCode(269)+"uje, že soubory stažené z t"+String.fromCharCode(283)+"chto internetových stránek neobsahují viry "+String.fromCharCode(269)+"i že nezp"+String.fromCharCode(367)+"sobí problémy s po"+String.fromCharCode(269)+"íta"+String.fromCharCode(269)+"em.";
		s += "\n\n";
		s += "P"+String.fromCharCode(345)+"e"+String.fromCharCode(269)+"etl(a) jsem si toto z"+String.fromCharCode(345)+"eknutí se odpov"+String.fromCharCode(283)+"dnosti";
	}	
	else if (xLang == 'da')
	{
		s = "Nĺr du klikker pĺ disse links forlader du Cystistat hjemmeside. ";
		s += "Holdningerne og anbefalingerne pĺ hjemmesiderne er ikke godkendt eller garanteret af Bioniche Pharma Limited. Det er udelukkende forfatterens egen holdning og anbefaling. ";
		s += "Bioniche fralćgger sig al ansvar og lovmćssig ansvarlighed vedrřrende  informationsindholdet eller til refererencer publiceret af andre eller linket til andre hjemmesider . ";
		s += "Ingen garantier kan vćre bindende, og alle fralćgges i det fulde omfang som loven tillader.";
		s += "Elektroniske filer eller software som er downloadet fra internettet kan indeholde virus eller andre risici og Bioniche giver ingen garantier for at filer downloadet fra disse hjemmesider er fri for virus eller ikke skaber computerproblemer. ";
		s += "\n\n";
		s += "Jeg har lćst denne erklćring.";		
	}	
	else
	{
		s = "By clicking on the links you will leave the Cystistat website.\n\n";
		s += "None of the opinions or recommendations expressed on the websites linked are endorsed or vouched for by Bioniche Pharma Limited. They must be taken solely as the opinions of their authors.";
		s += "Bioniche expressly disclaims all liability and legal responsibility for the information contained or referenced in, posted by others in, or linked to these websites. No warranties may be implied, but all are expressly disclaimed to the full extent permitted by law.";	
		s += "Electronic files and software downloaded over the internet can contain viruses and other risks, and Bioniche makes no guarantee that files downloaded from these websites will be virus-free or will not cause computer problems.";
		s += "\n\n";
		s += "I have read this disclaimer.";
	}
	
	if (! confirm(s))
	{
	    window.history.back();
	}
}
