var count = 0; var text = "    Red Sea Duiken *  Duiken Sharm El Sheikh  *  Duiken Hurghada  *  Duiken Dahab   **   Welkom bij Red Sea Diving International Web Site   **   15% Korting voor Advance reserveren   **   Red Sea Duiken Site Maps    ***";


/* Navigation languages */

function langen() 
{ var goto = "http://www.diversintl.com/" + sitename + ".php";
  self.location.href = goto; }
function langde() 
{ var goto = "http://german.diversintl.com/" + sitename + ".php";
  self.location.href = goto; }
function langfr() 
{ var goto = "http://french.diversintl.com/" + sitename + ".php";
  self.location.href = goto; }
function langdu() 
{ var goto = "http://dutch.diversintl.com/" + sitename + ".php";
  self.location.href = goto; }



function  scroll () {
    window.status = text.substring (count, text.length) + text.substring
(0, count)
    if (count < text.length)
      count ++;
    else
      count = 0;
    setTimeout ("scroll()", 150);
    }


// login.php page to log User In.
function loginn()
{
do {

		var x;
		x=forma.usernam.value;
		if((x.length==0) || (x.charAt(0)==' '))
		{
			alert(errorMsg0);
//			alert("put username");
			forma.usernam.value="";			
			forma.usernam.focus();
			return false;
			break;
		}

		var z;
		z=forma.passwrd.value;
		if((z.length==0) || (z.charAt(0)==' '))
		{
//			alert(errorMsg1);
			alert(errorMsg1);
			forma.passwrd.value="";
			forma.passwrd.focus(); 	
			return false;
			break;
		}

	} while(0)
}

// login.php page to send password by e-mail to user.
function sndpsw() {
		
	do
	{
		f=paswordo.emailo.value;
		if((f.length==0) || (f.charAt(0)==' '))
		{
			alert(errorMsg2);
			paswordo.emailo.value="";			
			paswordo.emailo.focus();
			return false;
		}

	} while(0)
}
function detailso(x,y){
	
		switch(x) {
			
			case 1:
			x = "tir";
			break;

			case 2:
			x = "loc";
			break;

			case 3:
			x = "ras";
			break;

			case 4:
			x = "gub";
			break;
		}

		moni=window.open('details_'+x+'.php','geo','width=693, height='+y+', status=0, scrollbars=0, left=16, top=30');
		moni.focus();

}

function detailso2(x,y,z){

		switch(x) {
			
			case 11:
			x = "tir_det";
			break;

			case 22:
			x = "loc_det";
			break;

			case 33:
			x = "ras_det";
			break;

			case 44:
			x = "gub_det";
			break;
		}

		moni=window.open('details_'+x+'.php?img='+y+'','geo2','width=750, height='+z+', status=0, scrollbars=0, left=50, top=110');
		moni.focus();

}
