<!--
today=new Date();
jran=today.getTime();
var number = 6;
var random_number="";
var random_number2="";
var quote="";
var client="";
ia=9301;
ic=49297;
im=233280;
jran = (jran*ia+ic) % im;
random_number = Math.ceil( (jran/(im*1.0)) *number);
random_number2 = Math.ceil( (jran/(im*1.0)) *number);

// Loads the appropriate image based on random number.

if (random_number==1) {
	URL="/p-cga.html";
	plaatje="/images/homeRotation/cga.gif";
}
if (random_number==2) {
	URL="/w-access.html";
	plaatje="/images/homeRotation/access.gif";
}
if (random_number==3) {
	URL="/w-trib-AR.html";
	plaatje="/images/homeRotation/trib-AR.gif";
}
if (random_number==4) {
	URL="/web.html";
	plaatje="/images/homeRotation/punish.gif";
}
if (random_number>=5) {
	URL="/web.html";
	plaatje="/images/homeRotation/corral.gif";
}
if (random_number2==1) {
	titleText="<img src=\"/images/type/realize_your_vision.png\" width=\"300\" height=\"24\" alt=\"Realize your vision\">";
}
if (random_number2==2) {
	titleText="<img src=\"/images/type/enhance_your_image.png\" width=\"300\" height=\"24\" alt=\"Enhance your image\">";
}
if (random_number2==3) {
	titleText="<img src=\"/images/type/deliver_your_message.png\" width=\"300\" height=\"24\" alt=\"Deliver your message\">";
}
if (random_number2==4) {
	titleText="<img src=\"/images/type/punishInefficiency.gif\" width=\"160\" height=\"24\" alt=\"Punish inefficiency\">";
}
if (random_number2>=5) {
	titleText="<img src=\"/images/type/corral.gif\" width=\"137\" height=\"24\" alt\"Corral your data\">";
}

function doLogin() {
    username = document.getElementById("username").value;
    password = document.getElementById("password").value;
    if (username.length < 1 || password.length < 1)
	{
	alert("Please provide your username and password before logging in.");
	return false;
	}
    for (var i = 0; i < username.length; i++){      
	var ch = username.substring(i, i + 1);      
	if (((ch < "a" || "z" < ch) && (ch < "A" || "Z" < ch)) && (ch < "0" || "9" < ch)){         
	    alert('Your username contains only letters and numbers. Please reenter your username.');
	    return false;
	}      
    }

    for (var i = 0; i < password.length; i++){      
	var ch = password.substring(i, i + 1);      
	if (((ch < "a" || "z" < ch) && (ch < "A" || "Z" < ch)) && (ch < "0" || "9" < ch)){         
	    alert('Your password contains only letters and numbers. Please reenter your password.');
	    return false;
	}      
    }
    return true;
}

function doChangePassword() {
    pass1 = document.getElementById("newPassword1").value;
    pass2 = document.getElementById("newPassword2").value;
    if (pass1.length < 4 || pass2.length < 1)
	{
	alert("Please type and confirm a new password of 4-12 characters.");
	return false;
	}
    for (var i = 0; i < pass1.length; i++){
	var ch = pass1.substring(i, i + 1);      
	if (((ch < "a" || "z" < ch) && (ch < "A" || "Z" < ch)) && (ch < "0" || "9" < ch)){         
	    alert('Your password can contain only letters and numbers. Please reenter your password.');
	    return false;
	}      
    }

    if (pass1 != pass2) {
      alert('Passwords don\'t match.');
      return false;
    }
    return true;
}

function openDrawer(drawer)
{
  myDrawer = document.getElementById("drawer_"+drawer);
  myIcon = document.getElementById("drawerIcon_"+drawer);
  if (myDrawer.style.display == "none") {
    myDrawer.style.display = "";
    myIcon.src="/images/icons/closeFolder.png";
  }
  else {
    myDrawer.style.display = "none";
    myIcon.src="/images/icons/openFolder.png";
  }
}

    //-->
